Add plants:apply_review for reviewed conflict rulings (D-054) #176
Workflow file for this run
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: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: [master] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| container: ruby:3.4.10 | |
| services: | |
| db: | |
| image: postgres:13 | |
| env: | |
| POSTGRES_HOST_AUTH_METHOD: trust | |
| options: >- | |
| --health-cmd "pg_isready -U postgres" | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| env: | |
| RAILS_ENV: test | |
| SANDBOX: "true" | |
| SANDBOX_TRUST_LEVEL: "10" | |
| APPLICATION_JWT_ALGORITHM: RS256 | |
| APPLICATION_JWT_SECRET: ${{ secrets.APPLICATION_JWT_SECRET }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install postgresql-client | |
| run: apt-get update -qq && apt-get install -y --no-install-recommends postgresql-client | |
| - name: Configure bundler path | |
| run: bundle config set --local path vendor/bundle | |
| - name: Cache gems | |
| uses: actions/cache@v4 | |
| with: | |
| path: vendor/bundle | |
| key: ${{ runner.os }}-gems-${{ hashFiles('Gemfile.lock') }} | |
| restore-keys: | | |
| ${{ runner.os }}-gems- | |
| - name: Bundle install | |
| run: bundle install --jobs 4 | |
| - name: Set up database | |
| run: bundle exec rails db:create db:schema:load | |
| - name: Run RSpec | |
| run: bundle exec rspec | |
| - name: Schema drift gate | |
| run: | | |
| bundle exec rails graphql:schema:dump | |
| git config --global --add safe.directory "$GITHUB_WORKSPACE" || true | |
| git diff --exit-code schema.graphql | |
| - name: Run RuboCop | |
| run: bundle exec rubocop | |
| docker-build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@v3 | |
| - name: Build Docker image (production target) | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| target: production | |
| push: false | |
| cache-from: type=gha | |
| cache-to: type=gha,mode=max |