diff --git a/kanboard.sh b/kanboard.sh index bed398e..ed8e843 100755 --- a/kanboard.sh +++ b/kanboard.sh @@ -33,6 +33,7 @@ sudo -u postgres psql -f /tmp/kanboard-createdb.sql rm -f /tmp/kanboard-createdb.sql export PGPASSWORD=${KANBOARD_PWD} psql -f /srv/kanboard/app/Schema/Sql/postgres.sql kanboard kanboard +unset PGPASSWORD # Configure Kanboard envsubst <${SOURCE_DIR}/kanboard/srv/kanboard/config.php >/srv/kanboard/config.php @@ -40,8 +41,7 @@ export KANBOARD_ADMIN_USER=admin export KANBOARD_ADMIN_PWD=$(head -c 12 /dev/urandom | base64) export KANBOARD_ADMIN_HASH=$(php -r "echo password_hash('${KANBOARD_ADMIN_PWD}', PASSWORD_BCRYPT);") envsubst <${SOURCE_DIR}/kanboard/tmp/kanboard-adminpwd.sql >/tmp/kanboard-adminpwd.sql -psql -f /tmp/kanboard-adminpwd.sql kanboard kanboard -unset PGPASSWORD +sudo -u postgres psql -f /tmp/kanboard-adminpwd.sql kanboard # Create OS user adduser --system --group --home /srv/kanboard --shell /bin/false kanboard