update_prefix_config: Use https when enabled

This commit updates the 'update_prefix_config.sh' script to use an
'https://' as opposed to an 'http://' url when support is enabled.
This commit is contained in:
Tom Wiesing 2022-08-03 18:27:25 +02:00
parent 5170cc5dda
commit 1d1f61e6b4
No known key found for this signature in database
2 changed files with 11 additions and 1 deletions

View file

@ -43,6 +43,16 @@ function compute_instance_domain() {
}
INSTANCE_DOMAIN="$(compute_instance_domain "$SLUG")"
# compute the url pointing to an instance
function compute_instance_url() {
if [ -n "$CERTBOT_EMAIL" ]; then
echo -n "https://"
else
echo "http://"
fi
compute_instance_domain "$@"
}
# Next we need a username base.
# This will be used as a username across the system (linux), MySQL and GraphDB.
# For this we can only allow [0-9a-zA-Z-], hence we have to escape.