From 108fd72c862a06cd0f7676bf56993c0be7cadc03 Mon Sep 17 00:00:00 2001 From: xZero707 Date: Tue, 29 Oct 2024 19:39:22 +0100 Subject: [PATCH] Verify successful init install --- .../etc/s6-overlay/s6-rc.d/init-install-wordpress/run | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/rootfs/etc/s6-overlay/s6-rc.d/init-install-wordpress/run b/rootfs/etc/s6-overlay/s6-rc.d/init-install-wordpress/run index 07d6fd3..fb8dab8 100755 --- a/rootfs/etc/s6-overlay/s6-rc.d/init-install-wordpress/run +++ b/rootfs/etc/s6-overlay/s6-rc.d/init-install-wordpress/run @@ -54,5 +54,15 @@ main() { --admin_email="${WORDPRESS_INIT_ADMIN_EMAIL:?}" \ --skip-email + sleep 0.5 + + # Check if WordPress is already installed + if wp core is-installed 2>&1; then + echo "WordPress installed successfully at ${WORDPRESS_INIT_SITE_URL}" + return 0 + fi + + echo "Error: WordPress installation failed" + return 1 } main