|
|
@ -49,7 +49,7 @@ jobs: |
|
|
|
ssh-private-key: ${{ secrets.EC2_PRIVATE_KEY }} |
|
|
|
ssh-private-key: ${{ secrets.EC2_PRIVATE_KEY }} |
|
|
|
- name: Deploy app to EC2 |
|
|
|
- name: Deploy app to EC2 |
|
|
|
run: | |
|
|
|
run: | |
|
|
|
rsync -apvz --delete --no-times --exclude "configuration" -e "ssh -o StrictHostKeyChecking=no" -p ./ ${{ secrets.EC2_USERNAME }}@${{ secrets.EC2_HOST }}:/var/www/v2.roadmap.sh/ |
|
|
|
rsync -apvz --delete --no-times --exclude "configuration" -e "ssh -o StrictHostKeyChecking=no" -p ./ ${{ secrets.EC2_USERNAME }}@${{ secrets.EC2_HOST }}:/var/www/roadmap.sh/ |
|
|
|
- name: Restart PM2 |
|
|
|
- name: Restart PM2 |
|
|
|
uses: appleboy/ssh-action@master |
|
|
|
uses: appleboy/ssh-action@master |
|
|
|
with: |
|
|
|
with: |
|
|
@ -57,7 +57,7 @@ jobs: |
|
|
|
username: ${{ secrets.EC2_USERNAME }} |
|
|
|
username: ${{ secrets.EC2_USERNAME }} |
|
|
|
key: ${{ secrets.EC2_PRIVATE_KEY }} |
|
|
|
key: ${{ secrets.EC2_PRIVATE_KEY }} |
|
|
|
script: | |
|
|
|
script: | |
|
|
|
cd /var/www/v2.roadmap.sh |
|
|
|
cd /var/www/roadmap.sh |
|
|
|
sudo pm2 restart web-roadmap |
|
|
|
sudo pm2 restart web-roadmap |
|
|
|
|
|
|
|
|
|
|
|
# -------------------- |
|
|
|
# -------------------- |
|
|
|