fix: changed one mentor photo #81
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: 'Continuous Integration' | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| jobs: | |
| ci: | |
| name: 'Continuous Integration' | |
| runs-on: ubuntu-latest | |
| services: | |
| postgres: | |
| image: postgres | |
| env: | |
| POSTGRES_USER: postgres | |
| POSTGRES_PASSWORD: postgres | |
| POSTGRES_DB: fmicodes | |
| options: >- | |
| --health-cmd pg_isready | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| ports: | |
| - 5432:5432 | |
| redis: | |
| image: redis | |
| options: >- | |
| --health-cmd "redis-cli ping" | |
| --health-interval 10s | |
| --health-timeout 5s | |
| --health-retries 5 | |
| ports: | |
| - 6379:6379 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| with: | |
| fetch-depth: 0 | |
| - name: Derive appropriate SHAs for base and head for `nx affected` commands | |
| uses: nrwl/nx-set-shas@v3 | |
| - name: Setup Node | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version: 20 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v2 | |
| with: | |
| version: 8 | |
| - name: Install dependencies | |
| run: pnpm install | |
| - name: Get environment files | |
| run: | | |
| curl -H "Authorization: token ${TOKEN}" https://raw.githubusercontent.com/fss-fmi/secrets/main/fmicodes/.env.development > .env | |
| curl -H "Authorization: token ${TOKEN}" https://raw.githubusercontent.com/fss-fmi/secrets/main/fmicodes/apps/fmicodes-api/.env.development > ./apps/fmicodes-api/.env | |
| curl -H "Authorization: token ${TOKEN}" https://raw.githubusercontent.com/fss-fmi/secrets/main/fmicodes/apps/fmicodes-site/.env.development > ./apps/fmicodes-api/.env | |
| curl -H "Authorization: token ${TOKEN}" https://raw.githubusercontent.com/fss-fmi/secrets/main/fmicodes/apps/fmicodes-admin/.env.development > ./apps/fmicodes-admin/.env | |
| env: | |
| TOKEN: ${{ secrets.FSS_FMI_GITHUB_TOKEN }} | |
| - name: Build | |
| run: pnpm nx run-many -t build --parallel | |
| - name: Check formatting | |
| run: pnpm prettier . --check | |
| - name: Check linting | |
| run: pnpm nx run-many -t lint --parallel | |
| - name: Test | |
| run: pnpm nx run-many -t test --parallel --configuration=ci | |
| - name: E2E | |
| run: | | |
| pnpm prisma migrate dev | |
| pnpm nx run-many -t e2e --parallel=false |