Skip to content

Commit 2815977

Browse files
authored
Update deploy.yml
1 parent e3fbd28 commit 2815977

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.github/workflows/deploy.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,10 @@ jobs:
2323
2424
- name: SSH and deploy
2525
run: |
26-
ssh ${{ secrets.EC2_USER }}@${{ secrets.EC2_HOST }} "cd ~ && ./deploy.sh"
26+
ssh ${{ secrets.EC2_USER }}@${{ secrets.EC2_HOST }} "\
27+
set -euo pipefail; \
28+
cd ~; \
29+
if [ ! -f ./deploy.sh ]; then echo '❌ deploy.sh not found in ~'; exit 1; fi; \
30+
sed -i 's/\r$//' ./deploy.sh || true; \
31+
chmod +x ./deploy.sh; \
32+
./deploy.sh"

0 commit comments

Comments
 (0)