Преглед изворни кода

Merge pull request #44 from andreapollastri/develop

Deploy script fix
Andrea Pollastri пре 5 година
родитељ
комит
f9962633bf
1 измењених фајлова са 6 додато и 2 уклоњено
  1. 6 2
      storage/app/scripts/deploy.sh

+ 6 - 2
storage/app/scripts/deploy.sh

@@ -1,13 +1,17 @@
 #!/bin/bash
 
 ######### REMOTE GIT CONFIGURATION #########
-REPO="git@github.com:andreapollastri/cipi.git" #Use your Github
-BRANCH="master" #Choose your branch
+GITHUB="andreapollastri/cipi.git" #Choose your Github private/public repo
+BRANCH="master" #Choose your repository branch here
 
 ######### DO NOT CHANGE ANYTHING IN THIS AREA #########
+SSH_KEY="/home/###CIPI-USER###/git/deploy"
 WORK_TREE="/home/###CIPI-USER###/web"
 GIT_DIR="/home/###CIPI-USER###/git/deploy.git"
+chmod 600 $SSH_KEY
 eval $(ssh-agent -s)
+ssh-add $SSH_KEY
+REPO="git@github.com:$GITHUB"
 if [ -d "$GIT_DIR" ]; then
     cd $WORK_TREE
     git --work-tree=$WORK_TREE --git-dir=$GIT_DIR fetch