mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-12-24 07:37:04 +00:00
Render the lsb_release at flask init time
Don't change the index.html file at setup time
This commit is contained in:
parent
b562e7eefa
commit
515a74ba11
@ -101,9 +101,12 @@ def index():
|
||||
utils.fix_boto() # must call prior to importing boto
|
||||
import boto.s3
|
||||
backup_s3_hosts = [(r.name, r.endpoint) for r in boto.s3.regions()]
|
||||
lsb=utils.shell("check_output", ["/usr/bin/lsb_release", "-d"])
|
||||
|
||||
return render_template('index.html',
|
||||
hostname=env['PRIMARY_HOSTNAME'],
|
||||
distname=lsb[lsb.find("\t")+1:-1],
|
||||
|
||||
storage_root=env['STORAGE_ROOT'],
|
||||
|
||||
no_users_exist=no_users_exist,
|
||||
|
@ -180,7 +180,7 @@
|
||||
<hr>
|
||||
|
||||
<footer>
|
||||
<p>This is a <a href="https://github.com/ddavness/power-mailinabox">Power Mail-in-a-Box</a>, using !!___DIST_TAG___!!
|
||||
<p>This is a <a href="https://github.com/ddavness/power-mailinabox">Power Mail-in-a-Box</a> - {{distname}}
|
||||
</p>
|
||||
</footer>
|
||||
</div> <!-- /container -->
|
||||
|
@ -18,8 +18,6 @@ if [ "$OS" != "Debian GNU/Linux 10 (buster)" -a "$OS" != "Ubuntu 20.04 LTS" ]; t
|
||||
exit 1
|
||||
fi
|
||||
|
||||
sed -i "s|!!___DIST_TAG___!!|${OS}|g" management/templates/index.html
|
||||
|
||||
# Check that we have enough memory.
|
||||
#
|
||||
# /proc/meminfo reports free memory in kibibytes. Our baseline will be 512 MB,
|
||||
|
Loading…
Reference in New Issue
Block a user