Skip to content

Commit

Permalink
ci: fix prax website deploy
Browse files Browse the repository at this point in the history
Restores some crucial Firebase configs to straighten out the CD pipeline
for updating the prax marketing website, hosted on Firebase.
Uses a custom runner, to reduce job time from ~12m on ubuntu-latest to
~5m on the faster version.
  • Loading branch information
conorsch committed Jun 14, 2024
1 parent 236e650 commit 644a303
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 5 deletions.
5 changes: 5 additions & 0 deletions .firebaserc
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"projects": {
"default": "prax-website-1aea3"
}
}
15 changes: 10 additions & 5 deletions .github/workflows/deploy-firebase.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,27 @@ on:
jobs:
build:
name: Deploy
runs-on: ubuntu-latest
# The build step takes a lot of CPU, so we'll bump up to 8 vCPUs.
runs-on: buildjet-8vcpu-ubuntu-2204
steps:
- name: Checkout the source code
uses: actions/checkout@v4

- uses: pnpm/action-setup@v3
- name: Install pnpm
uses: pnpm/action-setup@v3
with:
version: 8

- name: Install dependencies
- name: Install npm dependencies
run: pnpm install

- name: Install wasm-pack
uses: jetli/[email protected]
with:
version: 'latest'

- name: Build static site
run: pnpm build
working-directory: apps/prax-marketing-site

- name: Deploy dapp static site to firebase
# N.B. the firebase-action helper doesn't support semver, e.g. `@v13`,
Expand All @@ -37,4 +43,3 @@ jobs:
args: deploy
env:
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
PROJECT_PATH: apps/prax-marketing-site/dist
10 changes: 10 additions & 0 deletions firebase.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"hosting": {
"public": "apps/prax-marketing-site/dist",
"ignore": [
"firebase.json",
"**/.*",
"**/node_modules/**"
]
}
}

0 comments on commit 644a303

Please sign in to comment.