Skip to content

Commit

Permalink
Remove default value in favour of env var
Browse files Browse the repository at this point in the history
  • Loading branch information
ostefano committed Aug 19, 2024
1 parent 60902db commit 7ef14a0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
6 changes: 3 additions & 3 deletions core/files/configure_misp.sh
Original file line number Diff line number Diff line change
Expand Up @@ -221,10 +221,10 @@ init_user() {
# Create the main user if it is not there already
sudo -u www-data /var/www/MISP/app/Console/cake user init -q > /dev/null 2>&1

echo "UPDATE misp.users SET email = \"${ADMIN_EMAIL}\" WHERE id = 1;" | ${MYSQLCMD}
echo "UPDATE $MYSQL_DATABASE.users SET email = \"${ADMIN_EMAIL}\" WHERE id = 1;" | ${MYSQLCMD}

if [ ! -z "$ADMIN_ORG" ]; then
echo "UPDATE misp.organisations SET name = \"${ADMIN_ORG}\" where id = 1;" | ${MYSQLCMD}
echo "UPDATE $MYSQL_DATABASE.organisations SET name = \"${ADMIN_ORG}\" where id = 1;" | ${MYSQLCMD}
fi

if [ -n "$ADMIN_KEY" ]; then
Expand Down Expand Up @@ -254,7 +254,7 @@ init_user() {
else
echo "... setting admin password skipped"
fi
echo 'UPDATE misp.users SET change_pw = 0 WHERE id = 1;' | ${MYSQLCMD}
echo "UPDATE $MYSQL_DATABASE.users SET change_pw = 0 WHERE id = 1;" | ${MYSQLCMD}
}

apply_critical_fixes() {
Expand Down
3 changes: 0 additions & 3 deletions core/files/etc/misp-docker/minimum_config.defaults.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,6 @@
"SimpleBackgroundJobs.redis_database": {
"default_value": 1
},
"SimpleBackgroundJobs.redis_password": {
"default_value": ""
},
"SimpleBackgroundJobs.redis_namespace": {
"default_value": "background_jobs"
},
Expand Down

0 comments on commit 7ef14a0

Please sign in to comment.