Skip to content

Commit 48180ee

Browse files
fix(install): Finish via web reminder now shown under all relevant scenarios (#2223)
Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
1 parent 13f51c4 commit 48180ee

10 files changed

Lines changed: 70 additions & 40 deletions

File tree

27/apache/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

27/fpm-alpine/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

27/fpm/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

28/apache/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

28/fpm-alpine/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

28/fpm/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

29/apache/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

29/fpm-alpine/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

29/fpm/entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

docker-entrypoint.sh

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -186,6 +186,7 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
186186
file_env NEXTCLOUD_ADMIN_PASSWORD
187187
file_env NEXTCLOUD_ADMIN_USER
188188

189+
install=false
189190
if [ -n "${NEXTCLOUD_ADMIN_USER+x}" ] && [ -n "${NEXTCLOUD_ADMIN_PASSWORD+x}" ]; then
190191
# shellcheck disable=SC2016
191192
install_options='-n --admin-user "$NEXTCLOUD_ADMIN_USER" --admin-pass "$NEXTCLOUD_ADMIN_PASSWORD"'
@@ -201,7 +202,6 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
201202
file_env POSTGRES_PASSWORD
202203
file_env POSTGRES_USER
203204

204-
install=false
205205
if [ -n "${SQLITE_DATABASE+x}" ]; then
206206
echo "Installing with SQLite database"
207207
# shellcheck disable=SC2016
@@ -246,9 +246,12 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
246246
fi
247247

248248
run_path post-installation
249-
else
250-
echo "Please run the web-based installer on first connect!"
251-
fi
249+
fi
250+
fi
251+
# not enough specified to do a fully automated installation
252+
if [ "$install" = false ]; then
253+
echo "Next step: Access your instance to finish the web-based installation!"
254+
echo "Hint: You can specify NEXTCLOUD_ADMIN_USER and NEXTCLOUD_ADMIN_PASSWORD and the database variables _prior to first launch_ to fully automate initial installation."
252255
fi
253256
# Upgrade
254257
else

0 commit comments

Comments
 (0)