This commit is contained in:
2019-02-15 16:51:53 +01:00
parent 09389489f2
commit 5eeb4d6832
4 changed files with 92 additions and 39 deletions

View File

@ -1,12 +0,0 @@
SERVER=$(CreoleGet one_master)
IP=$(CreoleGet adresse_ip_eth0)
if [ $(CreoleGet one_database_type) = "mysql" && $(CreoleGet one_ha_role) = "leader" ]; then
HOST=$(CreoleGet one_database_host)
DB=$(CreoleGet one_database_name)
USER=$(CreoleGet one_database_user)
PASS=$(CreoleGet one_database_pass)
onedb sqlite2mysql -s /var/lib/one/one.db -u $USER -p $PASS -d $DB -S $HOST
systemctl stop opennebula
systemctl start opennebula
fi
onezone server-add 0 --name $SERVER --rpc http://$IP:2633/RPC2