fixed migration #1429
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: "Build & Test" | |
| on: | |
| - push | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| services: | |
| postgres: | |
| image: postgres | |
| env: | |
| POSTGRES_PASSWORD: password | |
| POSTGRES_USER: koala | |
| ports: | |
| - 25838:5432 | |
| env: | |
| DATABASE_HOST: "127.0.0.1" | |
| DATABASE_USER: koala | |
| DATABASE_PASSWORD: password | |
| DATABASE_PORT: 25838 | |
| OIDC_SIGNING_KEY: .github/test-signing-key.pem | |
| steps: | |
| - uses: "actions/checkout@v4" | |
| - name: "install Nix" | |
| uses: "cachix/install-nix-action@v23" | |
| - name: "Cache Nix packages" | |
| uses: cachix/cachix-action@v12 | |
| with: | |
| name: svsticky-constipated-koala | |
| signingKey: ${{ secrets.CACHIX_SIGNING_KEY }} | |
| - name: "Execute Ruby linter" | |
| run: nix-shell --run "bundle exec rubocop" | |
| - name: "Execute Haml linter" | |
| run: nix-shell --run "bundle exec haml-lint" | |
| - name: "Execute Javascript linter" | |
| run: nix-shell --run "npx prettier -c app/javascript/*" | |
| - name: "Check for security vulnerabilities" | |
| run: nix-shell --run "bundle exec brakeman" | |
| - name: "create database" | |
| run: nix-shell --run "bundle exec rake db:create --trace" | |
| - name: Start Redis | |
| uses: supercharge/redis-github-action@1.1.0 | |
| with: | |
| redis-version: 5 | |
| - name: "setup database" | |
| run: nix-shell --run "bundle exec rake db:setup --trace" | |
| - name: "run tests" | |
| run: nix-shell --run "bundle exec rake" |