mirror of
https://github.com/streetwriters/notesnook.git
synced 2026-09-03 04:31:46 +02:00
* ci: init zeit now * add now.json * add ssh key * execute script * add preinstall command * use sh to execute script * check * add env var
39 lines
1.1 KiB
YAML
39 lines
1.1 KiB
YAML
name: Build and Deploy
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
pull_request:
|
|
branches:
|
|
- master
|
|
jobs:
|
|
build-and-deploy:
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
GH_DEPLOY_KEY: ${{ secrets.GH_DEPLOY_KEY }}
|
|
steps:
|
|
- name: Checkout 🛎️
|
|
uses: actions/checkout@v2 # If you're using actions/checkout@v2 you must set persist-credentials to false in most cases for the deployment to work correctly.
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Setup SSH
|
|
uses: webfactory/ssh-agent@v0.2.0
|
|
with:
|
|
ssh-private-key: ${{ secrets.GH_SSH_KEY }}
|
|
|
|
- name: Use Node.js 12.x
|
|
uses: actions/setup-node@v1
|
|
with:
|
|
node-version: 12.x
|
|
- run: npm install
|
|
|
|
- name: Build and Deploy 🚀
|
|
uses: amondnet/now-deployment@v2
|
|
with:
|
|
zeit-token: ${{ secrets.ZEIT_TOKEN }}
|
|
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
now-args: "--prod"
|
|
now-org-id: "Wst8mhjfr4LzbjOe956M2Z4t"
|
|
now-project-id: "QmStgLZ26V8aowiAAdyYaFVjRDWP9T8GEUoR9iJFSSnpWJ"
|