Skip to content

Commit

Permalink
ci: update deploy.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
ahonn committed Mar 29, 2024
1 parent 553ed1d commit dc1492e
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,14 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: Install SSH
run: |
install -m 600 -D /dev/null ~/.ssh/id_rsa
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_ed25519
ssh-keyscan -H ${{ secrets.SSH_HOST }} > ~/.ssh/known_hosts
- name: Deploy
run: |
ssh ${{ secrets.SSH_HOST }} "cd ${{ secrets.WORK_DIR }} && echo ${{ secrets.PACKAGE_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin && bash ./update.sh && exit"
- name: cleanup
run: rm -rf ~/.ssh
uses: appleboy/[email protected]
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USERNAME }}
password: ${{ secrets.PASSWORD }}
key: ${{ secrets.SSH_PRIVATE_KEY }}
script: |
cd ${{ secrets.SSH_WORK_DIR }}
echo ${{ secrets.PACKAGE_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin
bash ./update.sh

0 comments on commit dc1492e

Please sign in to comment.