mirror of
https://github.com/N0rthernL1ghts/wordpress.git
synced 2025-12-08 14:02:41 +01:00
Adapt to the changes in docker-env-secrets module
This commit is contained in:
@@ -44,9 +44,7 @@ main() {
|
|||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
source /usr/local/bin/load_secrets
|
wp core install \
|
||||||
|
|
||||||
s6-envdir /run/secrets_normalized wp core install \
|
|
||||||
--url="${WORDPRESS_INIT_SITE_URL:?}" \
|
--url="${WORDPRESS_INIT_SITE_URL:?}" \
|
||||||
--title="${WORDPRESS_INIT_SITE_TITLE:-WordPress}" \
|
--title="${WORDPRESS_INIT_SITE_TITLE:-WordPress}" \
|
||||||
--admin_user="${WORDPRESS_INIT_ADMIN_USER:?}" \
|
--admin_user="${WORDPRESS_INIT_ADMIN_USER:?}" \
|
||||||
|
|||||||
@@ -70,8 +70,6 @@ main() {
|
|||||||
# This will prepend service name to all output from here
|
# This will prepend service name to all output from here
|
||||||
exec > >(while read -r line; do echo "[init-wpconfig-verify] ${line}"; done) 2>&1
|
exec > >(while read -r line; do echo "[init-wpconfig-verify] ${line}"; done) 2>&1
|
||||||
|
|
||||||
source /usr/local/bin/load_secrets
|
|
||||||
|
|
||||||
echo "Checking salts..."
|
echo "Checking salts..."
|
||||||
if ! checkSaltsEnv; then
|
if ! checkSaltsEnv; then
|
||||||
echo "^^^ Some or all of the salts are not set. Cannot continue."
|
echo "^^^ Some or all of the salts are not set. Cannot continue."
|
||||||
|
|||||||
@@ -1,21 +0,0 @@
|
|||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
load_dir_env() {
|
|
||||||
local dir="$1"
|
|
||||||
|
|
||||||
shopt -s nullglob
|
|
||||||
|
|
||||||
for file in "$dir"/*; do
|
|
||||||
if [ -f "$file" ] && [[ "$(basename "$file")" != *=* ]]; then
|
|
||||||
varName="$(basename "$file")"
|
|
||||||
value="$(<"$file")"
|
|
||||||
export "${varName}=${value}"
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
main() {
|
|
||||||
load_dir_env /run/secrets_normalized
|
|
||||||
}
|
|
||||||
|
|
||||||
main
|
|
||||||
Reference in New Issue
Block a user