Open diegobill opened 7 years ago
I can not use this (https://github.com/krobertson/xenserver-automater) xenserver-automater on ubuntu 16.04, I have to use systemd instead of xe-automator.conf (upstart), I create this configs:
[Unit] Description="XenServer Guest Configuration Automator" [Service] WorkingDirectory=/home/user ExecStart=/bin/bash xenserver-automater.sh Restart=always [Install] WantedBy=multi-user.target
#!/bin/bash /usr/sbin/xe-set-network /usr/sbin/xe-set-hostname /usr/sbin/generate-sshd-keys
UUID=`xe vm-install template=mytemplate new-name-label=newvm` xe vm-param-set uuid=$UUID xenstore-data:vm-data/ip=192.168.1.20 xe vm-param-set uuid=$UUID xenstore-data:vm-data/gw=192.168.1.254 xe vm-param-set uuid=$UUID xenstore-data:vm-data/nm=255.255.255.0 xe vm-param-set uuid=$UUID xenstore-data:vm-data/ns=192.168.1.254 xe vm-param-set uuid=$UUID xenstore-data:vm-data/dm=mydomain.com xe vm-start uuid=$UUID
It works now, I forgot to execute:
sudo systemctl enable xe-automator.service
And install :
apt-get install -y xenstore-utils
I can not use this (https://github.com/krobertson/xenserver-automater) xenserver-automater on ubuntu 16.04, I have to use systemd instead of xe-automator.conf (upstart), I create this configs: