GitHub Actions周りの整備 #9
This file contains 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: Lint | |
on: [pull_request] | |
jobs: | |
lint-api-rubocop: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup actions environment for API | |
uses: ./.github/actions/setup-api | |
- working-directory: ./api | |
run: bundle exec rubocop | |
lint-api-brakeman: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup actions environment for API | |
uses: ./.github/actions/setup-api | |
- working-directory: ./api | |
run: bundle exec brakeman | |
lint-api-bundle-audit: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup actions environment for API | |
uses: ./.github/actions/setup-api | |
- working-directory: ./api | |
run: bundle exec bundle-audit check --update | |
lint-ui-lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup actions environment for UI | |
uses: ./.github/actions/setup-ui | |
- working-directory: ./ui | |
run: yarn lint | |
build-api: | |
runs-on: ubuntu-latest | |
permissions: | |
id-token: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Deploy API container | |
uses: ./.github/actions/build-api | |
with: | |
tags: | | |
asia-northeast1-docker.pkg.dev/networkcontest/janog55/network-score-server-api:commit-${{ github.sha }} | |
build-ui: | |
runs-on: ubuntu-latest | |
permissions: | |
id-token: write | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Deploy UI container | |
uses: ./.github/actions/build-ui | |
with: | |
tags: | | |
asia-northeast1-docker.pkg.dev/networkcontest/janog55/network-score-server-ui:commit-${{ github.sha }} |