diff --git a/src/freedombone-app-etherpad b/src/freedombone-app-etherpad index 675ad761..37c21490 100755 --- a/src/freedombone-app-etherpad +++ b/src/freedombone-app-etherpad @@ -58,10 +58,10 @@ function change_password_etherpad { } function etherpad_create_database { - if [ ! $ETHERPAD_ADMIN_PASSWORD ]; then - if [ -f $IMAGE_PASSWORD_FILE ]; then - ETHERPAD_ADMIN_PASSWORD="$(printf `cat $IMAGE_PASSWORD_FILE`)" - else + if [ -f $IMAGE_PASSWORD_FILE ]; then + ETHERPAD_ADMIN_PASSWORD="$(printf `cat $IMAGE_PASSWORD_FILE`)" + else + if [ ! $ETHERPAD_ADMIN_PASSWORD ]; then ETHERPAD_ADMIN_PASSWORD="$(create_password ${MINIMUM_PASSWORD_LENGTH})" fi fi @@ -435,10 +435,10 @@ function install_etherpad { exit 7359 fi - if [ ! $ETHERPAD_ADMIN_PASSWORD ]; then - if [ -f $IMAGE_PASSWORD_FILE ]; then - ETHERPAD_ADMIN_PASSWORD="$(printf `cat $IMAGE_PASSWORD_FILE`)" - else + if [ -f $IMAGE_PASSWORD_FILE ]; then + ETHERPAD_ADMIN_PASSWORD="$(printf `cat $IMAGE_PASSWORD_FILE`)" + else + if [ ! $ETHERPAD_ADMIN_PASSWORD ]; then ETHERPAD_ADMIN_PASSWORD="$(create_password ${MINIMUM_PASSWORD_LENGTH})" fi fi