octavia/elements/certs-ramfs/post-install.d/30-enable-certs-ramfs-service
Takashi Kajinami 991e0da01e Remove sysvinit/upstart support
Recent modern operating systems commonly use systemd. Octavia no longer
supports very old version of Ubuntu/CentOS/Debian which use sysvinit or
upstart so supporting only systemd should be enough.

The remaining usage of the service command is replaced by the ones with
the systemctl command.

Change-Id: Ifc3f85bf280527c0f76b2c0e0db2be813249dafa
2024-06-12 01:09:06 +09:00

18 lines
285 B
Bash
Executable File

#!/bin/bash
if [ "${DIB_DEBUG_TRACE:-0}" -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
case "$DIB_INIT_SYSTEM" in
systemd)
systemctl enable certs-ramfs.service
;;
*)
echo "Unsupported init system $DIB_INIT_SYSTEM"
exit 1
;;
esac