Commit bcb987e5 authored by Syed Bilal Raees's avatar Syed Bilal Raees

git checkout branches to script

parent 7a013f8a
Pipeline #2103 passed with stage
in 9 seconds
...@@ -34,9 +34,11 @@ build_app: ...@@ -34,9 +34,11 @@ build_app:
- | - |
if [[ $CI_COMMIT_REF_NAME = master ]]; then if [[ $CI_COMMIT_REF_NAME = master ]]; then
echo "depoying to prod server" echo "depoying to prod server"
git checkout master
sudo systemctl start python.service sudo systemctl start python.service
elif [[ $CI_COMMIT_REF_NAME = dev ]]; then elif [[ $CI_COMMIT_REF_NAME = dev ]]; then
echo "it's a dev server" echo "it's a dev server"
git checkout dev
sudo systemctl start prod.service sudo systemctl start prod.service
else else
echo "hello world" echo "hello world"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment