feat: add operator dashboard #254
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: | |
| push: | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| sqlite: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - run: bundle exec rake | |
| javascript: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 | |
| with: | |
| node-version: "22" | |
| - run: npm ci | |
| - run: npm test | |
| - run: npx playwright install --with-deps chromium | |
| - run: npm run test:browser | |
| compatibility: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ruby-version: [ "3.3", "3.4", "4.0" ] | |
| rails-version: [ "8.0", "8.1" ] | |
| env: | |
| RAILS_VERSION: ${{ matrix.rails-version }} | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: ${{ matrix.ruby-version }} | |
| bundler-cache: false | |
| - run: bundle lock --update && bundle install --jobs 4 | |
| - run: bundle exec rake test | |
| redis: | |
| runs-on: ubuntu-latest | |
| services: | |
| redis: | |
| image: redis:7 | |
| ports: | |
| - 6379:6379 | |
| options: >- | |
| --health-cmd "redis-cli ping" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - run: bundle exec rake test TEST=test/integration/redis_wake_up_test.rb | |
| postgresql: | |
| runs-on: ubuntu-latest | |
| services: | |
| postgres: | |
| image: postgres:18 | |
| env: | |
| POSTGRES_USER: solid_objects | |
| POSTGRES_PASSWORD: solid_objects | |
| POSTGRES_DB: solid_objects_test | |
| ports: | |
| - 5432:5432 | |
| options: >- | |
| --health-cmd "pg_isready -U solid_objects" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 10 | |
| env: | |
| SOLID_OBJECTS_DATABASE_URL: postgresql://solid_objects:solid_objects@127.0.0.1:5432/solid_objects_test | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - run: bundle exec rake test | |
| mysql: | |
| runs-on: ubuntu-latest | |
| # Both clients speak MySQL but report different adapter names, negotiate | |
| # different connection collations, and name the same error code | |
| # differently, so passing on one proves nothing about the other. | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| client: [ mysql2, trilogy ] | |
| services: | |
| mysql: | |
| image: mysql:8.4 | |
| env: | |
| MYSQL_USER: solid_objects | |
| MYSQL_PASSWORD: solid_objects | |
| MYSQL_DATABASE: solid_objects_test | |
| MYSQL_ROOT_PASSWORD: root | |
| ports: | |
| - 3306:3306 | |
| options: >- | |
| --health-cmd "mysqladmin ping -h 127.0.0.1 -uroot -proot" | |
| --health-interval 5s | |
| --health-timeout 5s | |
| --health-retries 20 | |
| env: | |
| SOLID_OBJECTS_DATABASE_URL: ${{ matrix.client }}://solid_objects:solid_objects@127.0.0.1:3306/solid_objects_test | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - run: bundle exec rake test | |
| static: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - run: bundle exec rake standard rubocop rbs steep security | |
| release: | |
| if: startsWith(github.ref, 'refs/tags/v') | |
| needs: | |
| - sqlite | |
| - postgresql | |
| - mysql | |
| - static | |
| - javascript | |
| - compatibility | |
| - redis | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| id-token: write | |
| steps: | |
| - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7 | |
| with: | |
| persist-credentials: false | |
| - uses: ruby/setup-ruby@95ef2b042f9d7a56d8268cba8559e2842e2ad01b # v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - name: Verify release tag | |
| run: | | |
| version=$(ruby -Ilib -e 'require "solid_objects/version"; print SolidObjects::VERSION') | |
| test "$GITHUB_REF_NAME" = "v$version" | |
| - name: Build gem | |
| run: gem build solid_objects.gemspec | |
| - name: Configure RubyGems credentials | |
| uses: rubygems/configure-rubygems-credentials@dc5a8d8553e6ee01fc26761a49e99e733d17954a | |
| - name: Push to RubyGems | |
| run: gem push solid_objects-*.gem | |
| - name: Create GitHub release | |
| uses: softprops/action-gh-release@3bb12739c298aeb8a4eeaf626c5b8d85266b0e65 # v2 | |
| with: | |
| files: solid_objects-*.gem | |
| generate_release_notes: true |