Skip to content

fixed the wrong folder.. sort of #9

fixed the wrong folder.. sort of

fixed the wrong folder.. sort of #9

name: Undo Astroid API update via Github Actions
on:
release:
types: [unpublished]
jobs:
stop_api:
runs-on: ubuntu-latest
steps:
- name: API Shutdown
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USER }}
password: ${{ secrets.SSH_PASSWORD }}
port: ${{ secrets.SSH_PORT }}
script: |
sudo systemctl stop astroidapi
revoke_changes:
runs-on: ubuntu-latest
needs: stop_api
- name: Revert changes

Check failure on line 23 in .github/workflows/revoke_api_deploy.yaml

View workflow run for this annotation

GitHub Actions / .github/workflows/revoke_api_deploy.yaml

Invalid workflow file

You have an error in your yaml syntax on line 23
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USER }}
password: ${{ secrets.SSH_PASSWORD }}
port: ${{ secrets.SSH_PORT }}
script: |
cd /root/astroid
git reset --hard HEAD
git pull origin main
cp -r /root/astroid/src/astroidapi /root/guildcord/astroidapi
cp -r /root/astroid/src/api.py /root/guildcord/api.py
deploy_api:
runs-on: ubuntu-latest
needs: [stop_api, revoke_changes]
- name: Deploy API
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.SSH_HOST }}
username: ${{ secrets.SSH_USER }}
password: ${{ secrets.SSH_PASSWORD }}
port: ${{ secrets.SSH_PORT }}
script: |
sudo systemctl start astroidapi