Skip to content

Commit

Permalink
Merge pull request MariaDB#357 from grooverdan/password_complexity
Browse files Browse the repository at this point in the history
MARIADB_RANDOM_ROOT_PASSWORD - much more random
  • Loading branch information
grooverdan authored Mar 14, 2021
2 parents 6154928 + ad1e335 commit bf06c07
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion 10.2/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ docker_setup_db() {
fi
# Generate random root password
if [ -n "$MARIADB_RANDOM_ROOT_PASSWORD" ]; then
export MARIADB_ROOT_PASSWORD="$(pwgen -1 32)"
export MARIADB_ROOT_PASSWORD="$(pwgen --numerals --capitalize --symbols --remove-chars="'\\" -1 32)"
export MYSQL_ROOT_PASSWORD=$MARIADB_ROOT_PASSWORD
mysql_note "GENERATED ROOT PASSWORD: $MARIADB_ROOT_PASSWORD"
fi
Expand Down
2 changes: 1 addition & 1 deletion 10.3/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ docker_setup_db() {
fi
# Generate random root password
if [ -n "$MARIADB_RANDOM_ROOT_PASSWORD" ]; then
export MARIADB_ROOT_PASSWORD="$(pwgen -1 32)"
export MARIADB_ROOT_PASSWORD="$(pwgen --numerals --capitalize --symbols --remove-chars="'\\" -1 32)"
export MYSQL_ROOT_PASSWORD=$MARIADB_ROOT_PASSWORD
mysql_note "GENERATED ROOT PASSWORD: $MARIADB_ROOT_PASSWORD"
fi
Expand Down
2 changes: 1 addition & 1 deletion 10.4/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ docker_setup_db() {
fi
# Generate random root password
if [ -n "$MARIADB_RANDOM_ROOT_PASSWORD" ]; then
export MARIADB_ROOT_PASSWORD="$(pwgen -1 32)"
export MARIADB_ROOT_PASSWORD="$(pwgen --numerals --capitalize --symbols --remove-chars="'\\" -1 32)"
export MYSQL_ROOT_PASSWORD=$MARIADB_ROOT_PASSWORD
mysql_note "GENERATED ROOT PASSWORD: $MARIADB_ROOT_PASSWORD"
fi
Expand Down
2 changes: 1 addition & 1 deletion 10.5/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ docker_setup_db() {
fi
# Generate random root password
if [ -n "$MARIADB_RANDOM_ROOT_PASSWORD" ]; then
export MARIADB_ROOT_PASSWORD="$(pwgen -1 32)"
export MARIADB_ROOT_PASSWORD="$(pwgen --numerals --capitalize --symbols --remove-chars="'\\" -1 32)"
export MYSQL_ROOT_PASSWORD=$MARIADB_ROOT_PASSWORD
mysql_note "GENERATED ROOT PASSWORD: $MARIADB_ROOT_PASSWORD"
fi
Expand Down
2 changes: 1 addition & 1 deletion docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ docker_setup_db() {
fi
# Generate random root password
if [ -n "$MARIADB_RANDOM_ROOT_PASSWORD" ]; then
export MARIADB_ROOT_PASSWORD="$(pwgen -1 32)"
export MARIADB_ROOT_PASSWORD="$(pwgen --numerals --capitalize --symbols --remove-chars="'\\" -1 32)"
export MYSQL_ROOT_PASSWORD=$MARIADB_ROOT_PASSWORD
mysql_note "GENERATED ROOT PASSWORD: $MARIADB_ROOT_PASSWORD"
fi
Expand Down

0 comments on commit bf06c07

Please sign in to comment.