Skip to content

Commit 6e99733

Browse files
committed
chore(cd): fix ssh key handling for EC2 deploy
1 parent 89f6e60 commit 6e99733

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.github/workflows/cd.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ jobs:
4444
- name: Setup SSH
4545
run: |
4646
mkdir -p ~/.ssh
47-
echo "${{ secrets.EC2_SSH_KEY }}" > ~/.ssh/ec2.pem
47+
cat << 'EOF' > ~/.ssh/ec2.pem
48+
${{ secrets.EC2_SSH_KEY }}
49+
EOF
4850
chmod 600 ~/.ssh/ec2.pem
4951
ssh-keyscan -H ${{ secrets.EC2_HOST }} >> ~/.ssh/known_hosts
5052

0 commit comments

Comments
 (0)