Loading scripts/entrypoint.sh +16 −0 Original line number Diff line number Diff line Loading @@ -171,6 +171,8 @@ setup_components() { [[ $(wp theme list --status=active --format=count) -eq 0 ]] && wp theme activate $(wp theme list --field=name | head -n1) deactivate_missing_plugins setup_s3 return 0 Loading Loading @@ -221,6 +223,20 @@ collect_static() . static/ } deactivate_missing_plugins() { local plugin wp option get active_plugins --format=json | jq -r '.[]' | while read plugin; do test -e wp-content/plugins/$plugin && echo $plugin || echo >&2 "Deactivating removed plugin: $(dirname $plugin)" done | jq -R '[[.],[inputs]]|add' | wp option update active_plugins --format=json } next_cron() { echo $(($(wp cron event list --field=time|sort|head -n1) - $(date +%s))) Loading scripts/install-deps.sh +7 −0 Original line number Diff line number Diff line #!/bin/sh # Copyright 2019-2021 Dominik Sekotill <dom.sekotill@kodo.org.uk> # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. set -eux # Install packaged dependencies Loading @@ -6,6 +12,7 @@ apk update apk add \ bash \ imagemagick-libs \ jq \ libgmpxx \ libjpeg \ libpng \ Loading Loading
scripts/entrypoint.sh +16 −0 Original line number Diff line number Diff line Loading @@ -171,6 +171,8 @@ setup_components() { [[ $(wp theme list --status=active --format=count) -eq 0 ]] && wp theme activate $(wp theme list --field=name | head -n1) deactivate_missing_plugins setup_s3 return 0 Loading Loading @@ -221,6 +223,20 @@ collect_static() . static/ } deactivate_missing_plugins() { local plugin wp option get active_plugins --format=json | jq -r '.[]' | while read plugin; do test -e wp-content/plugins/$plugin && echo $plugin || echo >&2 "Deactivating removed plugin: $(dirname $plugin)" done | jq -R '[[.],[inputs]]|add' | wp option update active_plugins --format=json } next_cron() { echo $(($(wp cron event list --field=time|sort|head -n1) - $(date +%s))) Loading
scripts/install-deps.sh +7 −0 Original line number Diff line number Diff line #!/bin/sh # Copyright 2019-2021 Dominik Sekotill <dom.sekotill@kodo.org.uk> # # This Source Code Form is subject to the terms of the Mozilla Public # License, v. 2.0. If a copy of the MPL was not distributed with this # file, You can obtain one at http://mozilla.org/MPL/2.0/. set -eux # Install packaged dependencies Loading @@ -6,6 +12,7 @@ apk update apk add \ bash \ imagemagick-libs \ jq \ libgmpxx \ libjpeg \ libpng \ Loading