debian: use os-svc-enable to enable apache
apache service is called “httpd” on RHEL/Fedora and apache2 on Debian/Ubuntu/Fedora. As pointed by Ben Nemec, os-svc-enable is best way to deal with this complexity and thus support all the operating system properly. This commit requires change I125c46bebb0342ee3bdb957116e7c7e8e27a2ecc on diskimage-builder to be able to enable apache with os-svc-enable. Change-Id: I4720b61eb0fd15e539564edd25843f8332478abf
This commit is contained in:
parent
b9ff75ff85
commit
686a5e958c
|
@ -1,2 +1,3 @@
|
|||
os-apply-config
|
||||
os-refresh-config
|
||||
os-svc-install
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
#!/bin/bash
|
||||
set -eux
|
||||
|
||||
if [ "$DIB_INIT_SYSTEM" == "systemd" ]; then
|
||||
systemctl enable httpd.service
|
||||
fi
|
||||
os-svc-enable -n apache2
|
||||
|
|
Loading…
Reference in New Issue