Skip to content

Commit

Permalink
mbx: allow repo override and option to enable/disable SG and local st…
Browse files Browse the repository at this point in the history
…orage

Signed-off-by: Rohit Yadav <[email protected]>
  • Loading branch information
rohityadavcloud committed Jun 1, 2021
1 parent 80b0f00 commit a83cfde
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
2 changes: 2 additions & 0 deletions marvin/kvm.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
"name": "DC",
"guestcidraddress": "10.1.1.0/24",
"dns1": "8.8.8.8",
"localstorageenabled": "false",
"securitygroupenabled": "false",
"physical_networks": [
{
"broadcastdomainrange": "Zone",
Expand Down
2 changes: 2 additions & 0 deletions marvin/vmw.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
"name": "DC",
"guestcidraddress": "10.1.1.0/24",
"dns1": "8.8.8.8",
"localstorageenabled": "false",
"securitygroupenabled": "false",
"physical_networks": [
{
"broadcastdomainrange": "Zone",
Expand Down
2 changes: 2 additions & 0 deletions marvin/xen.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
"name": "DC",
"guestcidraddress": "10.1.1.0/24",
"dns1": "8.8.8.8",
"localstorageenabled": "false",
"securitygroupenabled": "false",
"physical_networks": [
{
"broadcastdomainrange": "Zone",
Expand Down
8 changes: 6 additions & 2 deletions mbx
Original file line number Diff line number Diff line change
Expand Up @@ -215,10 +215,10 @@ deploy() {
fi
done

# FIXME: configure provided rpm/deb repo on hosts

# Setup Management Server
msip=$(getent hosts $env-mgmt1 | awk '{ print $1 }')
# Fix CentOS7 repo
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$msip "sed -i '/^baseurl=.*/d' /etc/yum.repos.d/cloudstack.repo && echo baseurl=$repo >> /etc/yum.repos.d/cloudstack.repo"
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$msip systemctl enable --now mariadb
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$msip yum install -y cloudstack-management cloudstack-usage cloudstack-common cloudstack-integration-tests cloudstack-marvin
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$msip "cloudstack-setup-databases cloud:cloud@localhost --deploy-as=root: -i $msip"
Expand All @@ -227,8 +227,12 @@ deploy() {

# Setup KVM hosts
if [[ $hypervisor == "kvm" ]]; then
# Fix CentOS7 repo
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$env-host1 "sed -i '/^baseurl=.*/d' /etc/yum.repos.d/cloudstack.repo && echo baseurl=$repo >> /etc/yum.repos.d/cloudstack.repo"
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$env-host1 yum install -y cloudstack-agent
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$env-host1 "echo host.reserved.mem.mb=512 >> /etc/cloudstack/agent/agent.properties"
# Fix CentOS7 repo
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$env-host2 "sed -i '/^baseurl=.*/d' /etc/yum.repos.d/cloudstack.repo && echo baseurl=$repo >> /etc/yum.repos.d/cloudstack.repo"
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$env-host2 yum install -y cloudstack-agent
sshpass -p 'P@ssword123' ssh -o "UserKnownHostsFile=/dev/null" -o "StrictHostKeyChecking=no" root@$env-host2 "echo host.reserved.mem.mb=512 >> /etc/cloudstack/agent/agent.properties"
fi
Expand Down

0 comments on commit a83cfde

Please sign in to comment.