1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2024-12-22 07:17:05 +00:00

create a basic hello world page on http/https

This commit is contained in:
Joshua Tauberer 2013-09-08 09:55:58 +00:00
parent b770c5370b
commit b4e7d6ba5e
2 changed files with 14 additions and 0 deletions

9
conf/www_default.html Normal file
View File

@ -0,0 +1,9 @@
<html>
<head>
<title>this is a mailinabox</title>
</head>
<body>
<h1>this is a mailinabox</h1>
<p><a href="https://github.com/tauberer/mailinabox">https://github.com/tauberer/mailinabox</a></p>
</body>
</html>

View File

@ -9,12 +9,17 @@ rm -f /etc/nginx/sites-enabled/default
STORAGE_ROOT_ESC=$(echo $STORAGE_ROOT|sed 's/[\\\/&]/\\&/g')
PUBLIC_HOSTNAME_ESC=$(echo $PUBLIC_HOSTNAME|sed 's/[\\\/&]/\\&/g')
# copy in the nginx configuration file and substitute some
# variables
cat conf/nginx.conf \
| sed "s/\$STORAGE_ROOT/$STORAGE_ROOT_ESC/g" \
| sed "s/\$PUBLIC_HOSTNAME/$PUBLIC_HOSTNAME_ESC/g" \
> /etc/nginx/conf.d/local.conf
# make a default homepage
mkdir -p $STORAGE_ROOT/www/static
cp conf/www_default.html $STORAGE_ROOT/www/static/index.html
chown -R $STORAGE_USER $STORAGE_ROOT/www/static/index.html
service nginx restart