Cleanup step added
All checks were successful
Remote Deployment Pipeline / Prepare deployment vars (push) Successful in 3s
Remote Deployment Pipeline / Create remote directory (push) Successful in 7s
Remote Deployment Pipeline / Cleanup MR environment (push) Has been skipped
Remote Deployment Pipeline / Sync repository files (push) Successful in 18s
Remote Deployment Pipeline / Run docker-compose remotely (push) Successful in 5s

This commit is contained in:
kovagoadi
2025-10-26 20:15:37 +01:00
parent ac0ccebfb4
commit 6176d24e9d

View File

@@ -137,6 +137,9 @@ jobs:
}
chmod 644 ~/.ssh/known_hosts
- name: Run docker-compose down on remote host
run: ssh -p "$SSH_PORT" $SSH_USER@$SSH_HOST "cd ${{ needs.prepare_deployment_vars.outputs.deploy_path }} && docker-compose down"
- name: Delete deployment directory
run: |
ssh -p "$SSH_PORT" $SSH_USER@$SSH_HOST "if [ -d '${{ needs.prepare_deployment_vars.outputs.deploy_path }}' ]; then rm -rf '${{ needs.prepare_deployment_vars.outputs.deploy_path }}'; echo 'Directory removed.'; else echo 'Directory not found, skipping.'; fi"