2024-09-06 13:55:30 -07:00
|
|
|
name: SSH and echo to file
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
ssh:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: SSH into host
|
2024-09-12 14:19:15 -07:00
|
|
|
uses: appleboy/ssh-action@v1.0.3
|
2024-09-06 13:55:30 -07:00
|
|
|
with:
|
2024-09-12 14:19:15 -07:00
|
|
|
host: ${{ secrets.HOST_DOMAIN }}
|
2024-09-06 13:55:30 -07:00
|
|
|
username: ${{ secrets.HOST_USERNAME }}
|
2024-09-06 14:20:29 -07:00
|
|
|
key: ${{ secrets.RUNNER_SSH_PRIVATEKEY }}
|
2024-09-06 13:55:30 -07:00
|
|
|
script: |
|
|
|
|
echo "Hello, world!" >> ~/hello.txt
|