From edaa552fb568156889e2112cc65e18419f6f37fe Mon Sep 17 00:00:00 2001 From: pierreozoux Date: Mon, 2 Mar 2015 10:35:05 +0000 Subject: [PATCH] Automatically provision primary domain, closes #39 --- dockerfiles/services/piwik/startup-piwik.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dockerfiles/services/piwik/startup-piwik.sh b/dockerfiles/services/piwik/startup-piwik.sh index 4decf3a..4b5ba91 100644 --- a/dockerfiles/services/piwik/startup-piwik.sh +++ b/dockerfiles/services/piwik/startup-piwik.sh @@ -73,7 +73,8 @@ then if [ -z ${SITE_URL+x} ] then - SITE_URL="http://${URL}" + PRIMARY_DOMAIN=`echo $URL | cut -d. -f2,3` + SITE_URL="http://${PRIMARY_DOMAIN}" fi if [ -z ${SITE_TIMEZONE+x} ]