spcd/cd-synchronize-output
2024-03-23 00:21:07 +01:00

19 lines
343 B
Text
Executable file

apt-get install --yes 'rsync'
mkdir --parents ~/.ssh
echo '${{secrets.cd}}' > ~/.ssh/id_ed25519
chmod 400 ~/.ssh/id_ed25519
ls -al ~/.ssh
ssh \
-o StrictHostKeyChecking=accept-new \
'cd@de.tilde.link' \
-- \
hostname
rsync \
--archive \
--delete-before \
--verbose \
'out/' \
"cd@de.tilde.link:/cd/${GITHUB_REF_NAME}/${GITHUB_REPOSITORY}/"