diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 32fc34f1d598f62e7bf5c7f3bbd6d03db5593f0a..edf2d67681b0f695afcb6e5251e09a2999928af8 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -21,7 +21,6 @@ variables: # - production server : # PROD_HOST : deployment server hostname # PROD_LOGIN : user on deployment server -# PROD_PASS : password for user on deployment server # PROD_PATH : path base on deployment server LC_ALL: C.UTF-8 ANDROID_HOME: "/usr/local/android-sdk" # should already be defined in the Docker image @@ -124,7 +123,7 @@ deploy-ovh-dev: - build script: # Copie de la branche / du tag - - ./scripts/deploy-version.sh prod $PROD_LOGIN $PROD_HOST $PROD_DEV_PATH $PROD_PASS + - ./scripts/deploy-version.sh prod $PROD_LOGIN $PROD_HOST $PROD_DEV_PATH deploy-prod: stage: deploy-prod @@ -134,7 +133,7 @@ deploy-prod: dependencies: - build script: - - ./scripts/deploy-version.sh prod $PROD_LOGIN $PROD_HOST $PROD_PATH $PROD_PASS + - ./scripts/deploy-version.sh prod $PROD_LOGIN $PROD_HOST $PROD_PATH releases-nightly: stage: releases-nightly diff --git a/scripts/deploy-version.sh b/scripts/deploy-version.sh index c495e81e0255388d9e86f72562a7e822fb5e5898..1b44ee6525451708c29227875f15cdeb0a602c20 100755 --- a/scripts/deploy-version.sh +++ b/scripts/deploy-version.sh @@ -2,11 +2,11 @@ set -o errexit -# deploie l'appli sur le serveur $3 (user $2/mot de passe $5) dans le dossier $4 et met à jour le fichier index.html -# si la version est "stable" +# deploie l'appli sur le serveur $3 (user $2) dans le dossier $4 et met à jour le fichier index.html +# si la version est "prod" -if (( $# < 4 || $# > 5 )); then - echo "usage: $0 <version> <login> <server> <path> [<password>]" +if (( $# < 4 )); then + echo "usage: $0 <version> <login> <server> <path>" exit 1 fi @@ -14,7 +14,6 @@ VERSION="$1" LOGIN="$2" HOST="$3" DIR="$4" -PASS="$5" echo "$(basename $0): deploying version $VERSION in $LOGIN@$HOST:$DIR"