Skip to content
This repository has been archived by the owner on Jan 25, 2024. It is now read-only.

Build continuously

Build continuously #4

Workflow file for this run

name: Continuous Integration
on:
pull_request:
branches:
- master
push:
branches:
- master
jobs:
ci:
name: Continuous Integration
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '18'
- name: Install dependencies
run: yarn
- name: Lint
run: yarn lint
- name: Typecheck
run: yarn tsc
- name: Test
run: yarn test
- name: Build
run: yarn build
cd:
name: Continuous Deployment
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
runs-on: ubuntu-22.04
needs:
- ci
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
with:
driver-opts: image=moby/buildkit:master
- name: Login to Github Packages
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push app to GitHub Packages
uses: docker/build-push-action@v5
with:
file: Dockerfile
push: true
tags: ghcr.io/${{ github.repository_owner }}/${{ github.event.repository.name }}:latest