Skip to content

ci: fix deploy workflow #4

ci: fix deploy workflow

ci: fix deploy workflow #4

Workflow file for this run

name: Build and Deploy web app
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Deno
uses: denoland/setup-deno@v1
with:
deno-version: v1.x
- name: Check formatting
working-directory: src/app
run: make fmt-check
- name: Lint
working-directory: src/app
run: make lint
- name: Build
working-directory: src/app
run: make build
- name: Tar build
working-directory: src/app/build
run: tar -cvf artifact.tar *
- name: Upload Github Pages artifact
uses: actions/upload-artifact@v3
with:
name: github-pages
path: src/app/build/artifact.tar
deploy:
runs-on: ubuntu-latest
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to Github Pages
id: deployment
uses: actions/deploy-pages@v2
with:
artifact_name: github-pages
token: ${{ secrets.GITHUB_TOKEN }}