diff options
author | Chris Mytton <self@hecticjeff.net> | 2013-09-16 18:12:10 +0100 |
---|---|---|
committer | Chris Mytton <self@hecticjeff.net> | 2013-09-16 18:12:10 +0100 |
commit | 7fb201b040bad4112a2b36955be09f297fd6a0dd (patch) | |
tree | bb5815a0f345d4f5adf749b4071363c1580e69f8 /bin/site-specific-install.sh | |
parent | b44f9edab53f59fb442e5ee4db28cb25408c652c (diff) | |
parent | c8a06f8b1dec400ed68e609fbeba0f72c17f42e7 (diff) |
Merge branch 'master' into oxfordshire-usability-recommendations
Diffstat (limited to 'bin/site-specific-install.sh')
-rw-r--r-- | bin/site-specific-install.sh | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/bin/site-specific-install.sh b/bin/site-specific-install.sh index d3da12104..54d1c7154 100644 --- a/bin/site-specific-install.sh +++ b/bin/site-specific-install.sh @@ -1,7 +1,7 @@ #!/bin/sh # Set this to the version we want to check out -VERSION=${VERSION_OVERRIDE:-v1.2.4} +VERSION=${VERSION_OVERRIDE:-v1.2.5} PARENT_SCRIPT_URL=https://github.com/mysociety/commonlib/blob/master/bin/install-site.sh @@ -25,25 +25,33 @@ misuse() { [ -z "$HOST" ] && misuse HOST [ -z "$DISTRIBUTION" ] && misuse DISTRIBUTION [ -z "$VERSION" ] && misuse VERSION +[ -z "$DEVELOPMENT_INSTALL" ] && misuse DEVELOPMENT_INSTALL -install_nginx +add_locale cy_GB +add_locale nb_NO +add_locale de_CH install_postfix -# Check out the current released version -su -l -c "cd '$REPOSITORY' && git checkout '$VERSION'" "$UNIX_USER" +if [ ! "$DEVELOPMENT_INSTALL" = true ]; then + install_nginx + add_website_to_nginx + # Check out the current released version + su -l -c "cd '$REPOSITORY' && git checkout '$VERSION' && git submodule update" "$UNIX_USER" +fi install_website_packages su -l -c "touch '$DIRECTORY/admin-htpasswd'" "$UNIX_USER" -add_website_to_nginx - add_postgresql_user -su -l -c "$REPOSITORY/bin/install-as-user '$UNIX_USER' '$HOST' '$DIRECTORY'" "$UNIX_USER" +export DEVELOPMENT_INSTALL +su -c "$REPOSITORY/bin/install-as-user '$UNIX_USER' '$HOST' '$DIRECTORY'" "$UNIX_USER" -install_sysvinit_script +if [ ! "$DEVELOPMENT_INSTALL" = true ]; then + install_sysvinit_script +fi if [ $DEFAULT_SERVER = true ] && [ x != x$EC2_HOSTNAME ] then |