Migrate to new API version. #7
This file contains hidden or 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: Deploy | |
on: | |
push: | |
branches: | |
- develop | |
workflow_dispatch: | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Configure SSH | |
uses: shimataro/ssh-key-action@v2 | |
with: | |
name: id_ed25519 | |
key: ${{ secrets.SSH_KEY }} | |
known_hosts: ${{ secrets.SSH_KNOWN_HOSTS }} | |
- name: Deploy | |
run: | | |
COMMANDS=$(cat << EOF | |
set -euo pipefail | |
cd /srv/avptp/transit-info | |
git fetch | |
git reset --hard @{u} | |
npm ci | |
npm run build | |
EOF | |
) | |
ssh caddy@${{ secrets.WEB_HOST }} -p 22001 "${COMMANDS}" |