ssh,target
This commit is contained in:
parent
a540e0316f
commit
538b1b70fb
2 changed files with 11 additions and 2 deletions
11
cd-init
11
cd-init
|
@ -1,14 +1,23 @@
|
||||||
|
export SSH='cd@de.tilde.link'
|
||||||
|
|
||||||
|
export TARGET="${SSH}:/cd/${GITHUB_REF_NAME}/${GITHUB_REPOSITORY}"
|
||||||
|
|
||||||
|
# packages
|
||||||
|
|
||||||
apt-get install --yes \
|
apt-get install --yes \
|
||||||
'rsync' \
|
'rsync' \
|
||||||
'tree' \
|
'tree' \
|
||||||
|
|
||||||
|
# ssh
|
||||||
|
|
||||||
mkdir --parents ~/.ssh
|
mkdir --parents ~/.ssh
|
||||||
|
|
||||||
echo "${CD}" > ~/.ssh/id_ed25519
|
echo "${CD}" > ~/.ssh/id_ed25519
|
||||||
unset CD
|
unset CD
|
||||||
chmod 400 ~/.ssh/id_ed25519
|
chmod 400 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
ssh \
|
ssh \
|
||||||
-o StrictHostKeyChecking=accept-new \
|
-o StrictHostKeyChecking=accept-new \
|
||||||
'cd@de.tilde.link' \
|
"${SSH}" \
|
||||||
-- \
|
-- \
|
||||||
hostname
|
hostname
|
||||||
|
|
|
@ -3,4 +3,4 @@ rsync \
|
||||||
--delete-before \
|
--delete-before \
|
||||||
--verbose \
|
--verbose \
|
||||||
'out/' \
|
'out/' \
|
||||||
"cd@de.tilde.link:/cd/${GITHUB_REF_NAME}/${GITHUB_REPOSITORY}/"
|
"${TARGET}/"
|
||||||
|
|
Loading…
Reference in a new issue