Skip to content

Test

Test #2435

Workflow file for this run

name: CI
on: push
jobs:
build:
uses: kausaltech/github-actions/.github/workflows/build.yaml@main
with:
project_id: watch-ui
project_type: nextjs
secrets:
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
test:
needs: [build]
uses: ./.github/workflows/e2e-image.yaml
with:
image: ${{ needs.build.outputs.image }}:${{ needs.build.outputs.image_tag }}
instance_identifiers: sunnydale
backend_base_url: https://api.watch.kausal.tech/v1
build_id: ${{ needs.build.outputs.build_id }}
s3_endpoint: ${{ vars.BUILD_S3_ENDPOINT }}
s3_bucket: ${{ vars.BUILD_S3_BUCKET }}
secrets: inherit
deploy:
needs: [build]
uses: kausaltech/github-actions/.github/workflows/deploy.yaml@main
secrets:
gitops_pat: ${{ secrets.GHA_GITOPS_PAT }}
if: needs.build.outputs.deployment_env
with:
docker_image_repo: ${{ needs.build.outputs.image }}
docker_image_tag: ${{ needs.build.outputs.image_tag }}
project_id: watch-ui
build_id: ${{ needs.build.outputs.build_id }}
deployment_env: ${{ needs.build.outputs.deployment_env }}
deploy-dokku:
needs: [build, deploy]
runs-on: runner-prod
container:
image: dokku/ci-docker-image:latest
steps:
- name: Push to dokku
# uses: dokku/github-action@master
# uses: docker://dokku/ci-docker-image:latest
# with:
# args: dokku-deploy
run: dokku-deploy
env:
# GIT_SSH_COMMAND: 'ssh -vvv'
# FIXME: Make configurable
GIT_REMOTE_URL: 'ssh://[email protected]:26228/watch-new-prod'
SSH_PRIVATE_KEY: ${{ secrets.DOKKU_SSH_PRIVATE_KEY }}
# DEPLOY_DOCKER_IMAGE: ${{ github.repository }}:${{ github.sha }}
DEPLOY_DOCKER_IMAGE: ${{ needs.build.outputs.image }}:${{ needs.build.outputs.image_tag }}
TRACE: '1'
# GIT_PUSH_FLAGS: -v