diff --git a/.github/workflows/systemd-restart.yml b/.github/workflows/systemd-restart.yml index 7904360..484713b 100644 --- a/.github/workflows/systemd-restart.yml +++ b/.github/workflows/systemd-restart.yml @@ -1,5 +1,8 @@ name: remote ssh command -on: [push] +on: + push: + branches: + - main jobs: build: name: Build diff --git a/.github/workflows/systemd-test.yml b/.github/workflows/systemd-test.yml new file mode 100644 index 0000000..c2ad1e7 --- /dev/null +++ b/.github/workflows/systemd-test.yml @@ -0,0 +1,19 @@ +name: remote ssh command +on: + push: + branches: + - test +jobs: + build: + name: Build + runs-on: ubuntu-latest + steps: + - name: executing remote ssh commands using password + uses: appleboy/ssh-action@v1.2.2 + with: + host: ${{ secrets.SERVER_IP }} + username: ninty + port: ${{ secrets.PORT }} + passphrase: ${{ secrets.PASSPHRASE }} + key: ${{ secrets.SSH_PRIVATE_KEY }} + script: /home/ninty/testvolt.sh