Skip to content

prod: v20241114-01 #1153

prod: v20241114-01

prod: v20241114-01 #1153

Workflow file for this run

name: CI
on:
push:
branches: ["main", "prod"]
pull_request:
types: [opened, synchronize]
jobs:
build:
name: Lint, build and Test
timeout-minutes: 15
runs-on: ubuntu-latest
env:
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
NEXTAUTH_SECRET: ${{ vars.NEXTAUTH_SECRET }}
NEXT_PUBLIC_STRAPI_URL: ${{ secrets.NEXT_PUBLIC_STRAPI_URL }}
STRAPI_TOKEN: ${{ secrets.STRAPI_TOKEN }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v4
with:
node-version: 20.14.0
- uses: pnpm/action-setup@v4.0.0
with:
version: 9.1.4
- name: Install dependencies
run: pnpm install
- name: Prettier
run: pnpm run prettier
- name: Lint
run: pnpm run lint
- name: Build
run: pnpm run build
deploy:
runs-on: ubuntu-latest
needs: build
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/prod'
env:
SCALINGO_APP_NAME: ${{ github.ref == 'refs/heads/prod' && vars.SCALINGO_PROD_APP_NAME || vars.SCALINGO_STAGING_APP_NAME }}
steps:
- uses: actions/checkout@v4
- uses: kolok/deploy-to-scalingo@v1
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
known-host: ssh.osc-fr1.scalingo.com
app-name: ${{ env.SCALINGO_APP_NAME }}