Skip to content

Remove solid_queue from Rails 7.1 (issue with Ruby 3.0). #274

Remove solid_queue from Rails 7.1 (issue with Ruby 3.0).

Remove solid_queue from Rails 7.1 (issue with Ruby 3.0). #274

Workflow file for this run

name: Pipeline
on: push
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- run: bundle exec rubocop
test:
needs: check
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ruby: [2.7.5, 3.0.6, 3.1.4, 3.2.2]
rails: [6.0.6, 6.1.7, 7.0.4, 7.1.3, 7.2.1, 8.0.0]
exclude:
- ruby: 3.1.4
rails: 6.0.6
- ruby: 3.2.2
rails: 6.0.6
- ruby: 2.7.5
rails: 7.1.3
- ruby: 2.7.5
rails: 7.2.1
- ruby: 3.0.6
rails: 7.2.1
- ruby: 2.7.5
rails: 8.0.0
- ruby: 3.0.6
rails: 8.0.0
- ruby: 3.1.4
rails: 8.0.0
env:
RAILS_VERSION: ${{ matrix.rails }}
CUSTOM_RUBY_VERSION: ${{ matrix.ruby }}
MAKE: make --jobs 4
steps:
- uses: actions/checkout@v4
- name: Remove `Gemfile.lock` because this is a matrix job
run: rm Gemfile.lock
- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- run: bin/rails db:migrate
- run: BACKTRACE=1 bin/rails test
- name: Check if coverage LCOV file exists
uses: andstor/file-existence-action@v3
with:
files: coverage/lcov.info
id: lcov_exists
- name: Submit coverage to `coveralls.io` if LCOV file exists
uses: coverallsapp/github-action@main
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
if: steps.lcov_exists.outputs.files_exists == 'true'
deploy:
needs: test
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- run: git fetch --tags --force # Fix broken actions/checkout@v4.
- uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.DEPLOY_SSH_PRIVATE_KEY }}
- run: cat config/deploy.known_hosts >> ~/.ssh/known_hosts
- uses: docker/setup-buildx-action@v3
- uses: crazy-max/ghaction-github-runtime@v3
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
- run: bundle exec kamal setup
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PRODUCTION_KEY: ${{ secrets.PRODUCTION_KEY }}
# We use `kamal setup` rather than `kamal deploy` so if we add or reprovision nodes, they
# get configured and the env is always pushed.
- uses: snok/container-retention-policy@b95617ac96d929f7a37025691e1ad89be732fb46
with:
image-names: rails-rest-framework
cut-off: one minute ago UTC+2
skip-tags: latest
account-type: personal
token: ${{ secrets.GITHUB_TOKEN }}
token-type: github-token
release:
needs: test
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
fetch-tags: true
- run: git fetch --tags --force # Fix broken actions/checkout@v4.
- run: git describe
- uses: ruby/setup-ruby@v1
- run: gem build rest_framework.gemspec -o rest_framework.gem
- run: cat VERSION
- env:
GEM_HOST_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }}
run: gem push rest_framework.gem