diff options
author | nachoparker <nacho@ownyourbits.com> | 2018-03-29 13:57:39 +0300 |
---|---|---|
committer | nachoparker <nacho@ownyourbits.com> | 2018-04-01 19:08:10 +0300 |
commit | 925c6fe7e5ef094f61fb701a9aeb3d9618ac55b8 (patch) | |
tree | 239de40dba9a97aecf05fc24a14785afba75d622 /update.sh | |
parent | f31caf4d0411423230c58cbfed04072bea0a2d2e (diff) |
ncp-web: use random passwords for NC and ncp-webv0.53.7
Diffstat (limited to 'update.sh')
-rwxr-xr-x | update.sh | 24 |
1 files changed, 24 insertions, 0 deletions
@@ -270,6 +270,30 @@ EOF systemctl disable log2ram systemctl stop log2ram } + + # add new virtual host for initial password setup + cat > /etc/apache2/sites-available/ncp-activation.conf <<EOF +<VirtualHost _default_:443> + DocumentRoot /var/www/ncp-web/ + SSLEngine on + SSLCertificateFile /etc/ssl/certs/ssl-cert-snakeoil.pem + SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key + +</VirtualHost> +<Directory /var/www/ncp-web/> + <RequireAll> + + <RequireAny> + Require host localhost + Require local + Require ip 192.168 + Require ip 172 + Require ip 10 + </RequireAny> + + </RequireAll> +</Directory> +EOF } # end - only live updates exit 0 |