ci: test deploy job
All checks were successful
Deploy workflow / deploy (push) Successful in 33s

This commit is contained in:
Matthieu Bessat 2024-03-10 17:48:21 +01:00
parent e7509a9225
commit bbd3095727
3 changed files with 13 additions and 4 deletions

View file

@ -12,7 +12,8 @@ on:
jobs:
deploy:
runs-on: docker
# by default it runs on a node.js debian image
container:
image: code.forgejo.org/oci/node:20-bookworm
steps:
- name: Install rsync
run: apt update && apt install -y rsync
@ -39,12 +40,12 @@ jobs:
run: echo "${{ secrets.SRV06_DEPLOY_WEBSITE_SSH_KEY }}" > ~/.ssh/id_edsa
- name: Upload
env:
OUTPUT_PATH: "/warmd/etoiledebethleem/websites/main/${{ GITHUB_BASE_REF }}"
OUTPUT_PATH: "/warmd/etoiledebethleem/websites/main/"
REMOTE_USER: forgejo_actions_websites
SRV_HOST: srv06.lefuturiste.fr
run: |
rsync --perms --archive --stats \
rsync --perms --archive --stats -v \
-e 'ssh -i ~/.ssh/id_edsa -o StrictHostKeyChecking=no' ./public \
${REMOTE_USER}@${SRV_HOST}:${OUTPUT_PATH}
$REMOTE_USER@$SRV_HOST:$OUTPUT_PATH$GITHUB_REF_NAME