Skip to content

Commit 6c0dc2e

Browse files
authored
Restore this block
1 parent 4784a53 commit 6c0dc2e

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

.github/workflows/compile.yml

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -116,20 +116,15 @@ jobs:
116116
- name: Setup SSH
117117
run: |
118118
mkdir -p ~/.ssh
119-
chmod 700 ~/.ssh
120-
printf "%s\n" "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa
119+
echo "${{secrets.SSH_PRIVATE_KEY}}" > ~/.ssh/id_rsa
120+
echo "Host ${{ secrets.SSH_HOST }}" > ~/.ssh/config
121+
echo " User ${{ secrets.SSH_USERNAME }}" >> ~/.ssh/config
122+
echo " IdentityFile ~/.ssh/id_rsa" >> ~/.ssh/config
123+
ssh-keyscan ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
121124
chmod 600 ~/.ssh/id_rsa
122-
cat <<EOF > ~/.ssh/config
123-
Host remote-server
124-
HostName ${{ secrets.SSH_HOST }}
125-
User ${{ secrets.SSH_USERNAME }}
126-
IdentityFile ~/.ssh/id_rsa
127-
StrictHostKeyChecking no
128-
EOF
129-
#ssh-keyscan -H ${{ secrets.SSH_HOST }} >> ~/.ssh/known_hosts
130125
- name: Replace remote files
131126
run: |
132-
rsync -Pavz -e "ssh -i $HOME/.ssh/id_rsa" ./output/ remote-server:/
127+
rsync -Pavz -e "ssh -i $HOME/.ssh/id_rsa" ./output/ ${{ secrets.SSH_USERNAME}}@${{secrets.SSH_HOST}}:/
133128
134129
release-core:
135130
name: Release Core

0 commit comments

Comments
 (0)