[fix] Clean systemd services install and really fix firewall

This commit is contained in:
Jérôme Lebleu 2015-10-09 14:26:04 +02:00
parent 4e790e2626
commit 1beadf3051
4 changed files with 3 additions and 10 deletions

1
debian/postinst vendored
View file

@ -4,7 +4,6 @@ set -e
do_configure() {
rm -rf /var/cache/moulinette/*
service yunohost-api restart
if [ ! -f /etc/yunohost/installed ]; then
bash /usr/share/yunohost/hooks/conf_regen/01-yunohost

5
debian/rules vendored
View file

@ -5,11 +5,8 @@
#export DH_VERBOSE=1
%:
dh ${@} --with=python2
dh ${@} --with=python2,systemd
override_dh_installinit:
dh_systemd_enable --name yunohost-api
dh_systemd_enable --name yunohost-firewall --no-enable
dh_installinit --name=yunohost-api
dh_installinit --name=yunohost-firewall
dh_systemd_start

View file

@ -9,6 +9,3 @@ ExecStart=/usr/bin/yunohost firewall reload
ExecReload=/usr/bin/yunohost firewall reload
ExecStop=/usr/bin/yunohost firewall stop
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target

View file

@ -270,12 +270,12 @@ def tools_postinstall(domain, password, ignore_dyndns=False):
# Enable UPnP silently and reload firewall
firewall_upnp('enable', no_refresh=True)
os.system('touch /etc/yunohost/installed')
# Enable and start YunoHost firewall at boot time
os.system('update-rc.d yunohost-firewall enable')
os.system('service yunohost-firewall start')
os.system('touch /etc/yunohost/installed')
service_regenconf(force=True)
msignals.display(m18n.n('yunohost_configured'), 'success')