mirror of https://github.com/apache/cloudstack.git
base attempt to move disable services and selectively start them
This commit is contained in:
parent
5aac32d2b2
commit
ea6f0de8f0
|
|
@ -14,5 +14,5 @@ WantedBy=multi-user.target
|
|||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/opt/cloud/bin/setup/cloud-early-config
|
||||
RemainAfterExit=true
|
||||
RemainAfterExit=no
|
||||
TimeoutStartSec=5min
|
||||
|
|
|
|||
|
|
@ -9,5 +9,5 @@ WantedBy=multi-user.target
|
|||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/opt/cloud/bin/setup/postinit.sh
|
||||
RemainAfterExit=true
|
||||
RemainAfterExit=no
|
||||
TimeoutStartSec=10min
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
[Unit]
|
||||
Description=CloudStack Agent service
|
||||
After=cloud-early-config.service network.target local-fs.target
|
||||
After=cloud-early-config.service network.target cloud-postinit.service local-fs.target
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
|
|||
|
|
@ -1,16 +0,0 @@
|
|||
[Unit]
|
||||
Description=Service for virtual machines hosted on VMware
|
||||
Documentation=http://open-vm-tools.sourceforge.net/about.php
|
||||
ConditionVirtualization=vmware
|
||||
DefaultDependencies=no
|
||||
Before=cloud-init-local.service
|
||||
After=local-fs.target
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/vmtoolsd
|
||||
TimeoutStopSec=5
|
||||
Restart=always
|
||||
RestartSec=15
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
|
|
@ -31,10 +31,38 @@ fi
|
|||
sysctl -p
|
||||
|
||||
# HYPERVISOR exported by cloud-early-config
|
||||
# stop ntp conflicting with vmtools
|
||||
if [ "$HYPERVISOR" == "vmware" ]; then
|
||||
systemctl stop ntpd
|
||||
fi
|
||||
|
||||
case $HYPERVISOR in
|
||||
xen-pv|xen-domU)
|
||||
systemctl stop ntpd
|
||||
systemctl start xe-daemon xenstored
|
||||
;;
|
||||
xen-hvm)
|
||||
systemctl stop ntpd
|
||||
systemctl start xe-daemon xenstored
|
||||
|
||||
;;
|
||||
kvm)
|
||||
systemctl start qemu-guest-agent
|
||||
VPORT=$(find /dev/virtio-ports -type l -name '*.vport' 2>/dev/null|head -1)
|
||||
;;
|
||||
vmware)
|
||||
systemctl stop ntpd
|
||||
systemctl start vmtoolsd
|
||||
|
||||
;;
|
||||
virtualpc|hyperv)
|
||||
# Hyper-V is recognized as virtualpc hypervisor type. Boot args are passed using KVP Daemon
|
||||
systemctl start hyperv-daemons
|
||||
;;
|
||||
virtualbox)
|
||||
# Virtualbox is used to test the virtual router
|
||||
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
|
||||
|
||||
# Restart journald for setting changes to apply
|
||||
systemctl restart systemd-journald
|
||||
|
|
|
|||
|
|
@ -110,6 +110,9 @@ function configure_services() {
|
|||
systemctl disable xl2tpd
|
||||
systemctl disable vgauth
|
||||
|
||||
# Disable guest services which will selectively be started based on hypervisor
|
||||
systemctl disable vmtoolsd xe-daemon qemu-guest-agent hyperv-daemons xenstored
|
||||
|
||||
configure_apache2
|
||||
configure_strongswan
|
||||
configure_issue
|
||||
|
|
|
|||
Loading…
Reference in New Issue