Merge branch 'master' of https://github.com/dev-family/admiral #262
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- master | |
workflow_dispatch: | |
env: | |
DEPLOY_PATH: /root/app/other-projects/admiral/ | |
BUILD_SCRIPT_OUTPUT: dist | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- name: Install Dependencies | |
run: yarn | |
- name: Build Appliction | |
run: yarn build | |
- name: Deploy to Server | |
uses: appleboy/scp-action@master | |
with: | |
host: ${{ secrets.DEPLOY_SERVER_HOST }} | |
port: ${{ secrets.DEPLOY_SERVER_PORT }} | |
username: ${{ secrets.DEPLOY_SERVER_USERNAME }} | |
key: ${{ secrets.DEPLOY_SERVER_KEY }} | |
source: ${{ env.BUILD_SCRIPT_OUTPUT }} | |
target: ${{ env.DEPLOY_PATH }} | |
strip_components: 1 | |
- name: Done | |
run: echo "Deployed at https://admiral.dev.family" |