Last active
March 14, 2022 20:30
-
-
Save lucien144/8f2005adb5ea7bef13c12d1edf1cc7b3 to your computer and use it in GitHub Desktop.
Bitbucket Pipeline to Ubuntu server via bash script
This file contains hidden or 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
image: atlassian/default-image:2 | |
pipelines: | |
branches: | |
master: | |
- step: | |
deployment: production | |
script: | |
- cat ./deploy.sh | ssh $HOST_USER@$HOST_URL | |
- echo "Deploy step finished" |
This file contains hidden or 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
#!/bin/bash | |
echo "Deploy script started" | |
cd ~/web | |
git checkout master | |
git pull origin master | |
composer install | |
echo "Deploy script finished execution" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment