35 lines
790 B
YAML
35 lines
790 B
YAML
|
name: Deploy Functions
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
branches:
|
||
|
- master
|
||
|
paths:
|
||
|
- "functions/**"
|
||
|
- ".github/workflows/deploy-functions.yml"
|
||
|
|
||
|
workflow_dispatch:
|
||
|
|
||
|
jobs:
|
||
|
deploy-functions:
|
||
|
runs-on: ubuntu-latest
|
||
|
env:
|
||
|
LINGDOCS_NPM_TOKEN: ${{ secrets.LINGDOCS_NPM_TOKEN }}
|
||
|
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }}
|
||
|
steps:
|
||
|
- uses: actions/checkout@v4
|
||
|
- uses: actions/setup-node@v4
|
||
|
with:
|
||
|
node-version: 20
|
||
|
cache: "npm"
|
||
|
- run: npm install -g firebase-tools
|
||
|
- run: |
|
||
|
cp .npmrc functions
|
||
|
cd website
|
||
|
npm install
|
||
|
cd ..
|
||
|
cd functions
|
||
|
npm install
|
||
|
- name: deploy functions and hosting routes
|
||
|
run: firebase deploy -f --token ${FIREBASE_TOKEN}
|