Add Forgejo runner yaml
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed

This commit is contained in:
Sergio Durigan Junior 2024-09-08 17:37:08 -04:00
parent 3dc462fc6b
commit e033fa3d4b
Signed by: sergiodj
GPG key ID: D0EB762865FC5E36

View file

@ -0,0 +1,29 @@
on:
push:
branches:
- main
jobs:
deploy:
runs-on: debian-testing-slim
steps:
- name: Update systemand install deps
env:
DEBIAN_FRONTEND=noninteractive
run: |
apt-get update
apt-get install -y hugo rsync openssh-client
- name: Setup SSH
env:
SSH_KEY: ${{ secrets.ssh_key }}
run: |
mkdir ~/.ssh/
printf '%s\n' "${SSH_KEY}" > ~/.ssh/id_rsa
chmod 0700 ~/.ssh
chmod 0700 ~/.ssh/id_rsa
- name: Run Hugo
run: /usr/bin/hugo --verbose
- name: Run rsync
env:
SSH_PORT: ${{ secrets.ssh_port }}
run: /usr/bin/rsync --verbose --compress --archive --recursive --progress --checksum --delete --rsh="/usr/bin/ssh -4 -p ${SSH_PORT} -o StrictHostKeyChecking=no" public/ blog@sergiodj.net:.