Merge pull request #44 from Xcceleran-do/master #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to Production | |
on: | |
push: | |
branches: | |
- production # Triggers workflow on production branch update. | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@v2 | |
- name: Set up SSH | |
uses: webfactory/[email protected] | |
with: | |
ssh-private-key: ${{ secrets.ESUBALEW_MAC_SSH_PRIVATE_KEY }} # Access SSH key from secrets. | |
- name: Test SSH Connection | |
run: ssh -o StrictHostKeyChecking=no esubalew@${{ secrets.JUMP_SERVER_IP }} exit | |
- name: Sync Files to Target Server via Jump Server | |
run: | | |
scp -o "ProxyJump esubalew@${{ env.JUMP_SERVER_IP }}" -r ./ esubalew@${{ env.WORDPRESS_PRODUCTION_SERVER_IP }}:/testwp/mailing/ |