Fix Sigmah admin bcrypt hash generation

This commit is contained in:
Disassembler 2018-01-29 20:24:41 +01:00
parent 35ca12b96a
commit ebd58cb120
Signed by: Disassembler
GPG Key ID: 524BD33A0EE29499

View File

@ -27,7 +27,7 @@ export SIGMAH_ADMIN_USER=Admin
export SIGMAH_ADMIN_EMAIL=admin@example.com export SIGMAH_ADMIN_EMAIL=admin@example.com
export SIGMAH_ADMIN_PWD=$(head -c 12 /dev/urandom | base64) export SIGMAH_ADMIN_PWD=$(head -c 12 /dev/urandom | base64)
apk --no-cache add apache2-utils apk --no-cache add apache2-utils
export SIGMAH_ADMIN_HASH=$(htpasswd -bnBC 10 "" ${SIGMAH_ADMIN_PWD} | tr -d ':\n' | tr '$2y' '$2a') export SIGMAH_ADMIN_HASH=$(htpasswd -bnBC 10 "" ${SIGMAH_ADMIN_PWD} | tr -d ':\n' | sed 's/$2y/$2a/')
apk --no-cache del apache2-utils apk --no-cache del apache2-utils
sed -i "s|§OrganizationName§|Demo organization|g" /tmp/sigmah-newOrganizationLaunchScript.sql sed -i "s|§OrganizationName§|Demo organization|g" /tmp/sigmah-newOrganizationLaunchScript.sql
sed -i "s|§OrganizationLogoFilename§|logo.png|g" /tmp/sigmah-newOrganizationLaunchScript.sql sed -i "s|§OrganizationLogoFilename§|logo.png|g" /tmp/sigmah-newOrganizationLaunchScript.sql