Setup
To use this lab walkthrough of deploying WordPress using AWX with Abiquo XaaS, you will need access to an AWX system with a WordPress template, a VM template running Linux with cloud-init support, and a vCenter hypervisor connected to an external lab network with accessible IPs.
Find and reserve IPs
In the main menu go to the Infrastructure tab, select the Private tab then select your datacenter. Go to the Network tab and the External sub-tab and choose your network.
In the External IPs pane find some IPs that are not currently in use, if necessary they can be selected and reserved or quarantined to avoid them being used elsewhere. For more details see Put an IP address on a deny list
Create the rack, the physical machine and the allocation rule
In the main menu go to the Infrastructure tab, then select the Private tab. Choose your datacenter, then select the Servers tab.
Click the + add button on the Servers pane (“create physical machine or rack”), select Rack then name your rack.
Select your rack and click the + add button, this time selecting Create physical machine. Complete the dialog then select your hypervisor system.
Click the edit button next to the selected IP, and go to the Datastores tab. Select your datastore(s) and uncheck the Retrieve existing VMs box. Click Accept.
Go to the Allocation rules tab then click the + add button on the Datacenter pane to add a new rule.
Complete the rule dialog, allowing oversubscription as appropriate to your environment. In a production system, you should never overallocate CPUs or RAM.
Create the hardware profile
Go to the Hardware profiles tab then click the + add button underneath the list of types and select Type. Complete the dialog.
Click the + add button on the Hardware profiles pane. Complete the dialog.
Configure your enterprise
In the main menu go to the Users tab. Select your enterprise and click the pencil edit button at the bottom of the Enterprises list.
In the General section, add the name and default scope of the enterprise.
Go to Datacenters, select the Allowed datacenter then click the pencil edit button below.
Go to Hardware profiles, check the Enable hardware profiles checkbox and select your hardware profile.
Create the network
In the main menu go to Infrastructure → Private. Select your datacenter, go to Network. Select External from the sub-menu.
Click the + add button below the list of networks.
Complete the dialog with the details of an accessible external network.If necessary, add IPs. Click the + add button below the list of IPs and create 5 or 6 IP addresses in the network starting from the first available address.
Remove the remote service DHCP
In the main menu go to the Infrastructure tab, then select the Remote services tab. Select the DHCPv6 remote service, mark the protocol checkbox then click the pencil edit button below.
In the Locations tab delete the DHCPv6 service for the datacenter by clicking on the trash bin icon and then clicking Save.
Next, mark the protocol checkbox again and delete the remote service by clicking on the trash bin icon and confirming.
Repeat the process for the DHCP remote services.
Configure the template
In the main menu go to the Catalogue tab, select the datacenter, select the virtual machine template then choose edit from the template’s menu.
Choose the Disks tab then click the pencil edit button on the Disks pane.
Select the Allocation type “Thin”.
In the Advanced tab, complete the dialog.
Add the virtual datacenters
In the main menu go to the myCloud tab and click the + add button below the list of virtual datacenters. Complete the dialog.
Repeat the process to create more virtual datacenters as required.
Select your (first) virtual datacenter. Choose the Network tab then the External sub-tab. Choose the external network you created earlier then click the pencil edit button.
Check the Default network checkbox.
Repeat the process for any other virtual datacenters you created.
The setup is now finished, and the Abiquo is ready to deploy VMs with accessible IPs. Next we will configure the service.
Configure the service
Add the AWXRepoService
In the main menu go to the Catalogue tab, select Services, click the + add button then choose AWXRepoService.
Go to the Can be used by tab, click the + add button and select the entity “Enterprise”. Repeat to add the entity “Virtual datacenter”.
Go to the Properties tab and complete the dialog. In this demo system, we will only be using one AWX configuration, so we can add the AWX endpoint and credentials to the default service. Also add your Abiquo endpoint and credentials.
Configure and launch the AWXRepoService
To configure the AWXRepoService at enterprise level, in the main menu go to the Users tab, select your enterprise, go to the Service configurations tab, click the + add button in the Service configurations pane then choose AWXRepoService.
Note that you can also configure Service with an AWX system at the datacenter level, in which case the Enterprise Admin can enable it for a location and the end users can work with it in the virtual datacenter.In the Create service configuration popup, go to Properties, add the credentials and click save.
Back in the Service configuration pane, select AWXRepoService, then choose List workflows from the menu that appears alongside it to import the workflow.
A popup window will appear asking “Do you want to perform action List workflows?”. Click Accept.
In the subsequent popup, select the required subservice.
An Edit service configuration popup will appear, click Save.
Back in the Service configuration pane, select the workflow you have imported, then choose Launch from the menu that appears alongside it to launch the workflow.
In the Launch popup, select the virtual datacenter. Note that you can click the magnifying glass icon to display the details of the virtual datacenter. Click Accept to launch the job.
Abiquo obtains the parameters from the AWX workflow. Your Systems Administrator can create an appropriate configuration for your environment, so it could differ from the configuration shown here.
Tracking the job
We can see in Ansible (Views → Jobs → Select Job → Output) that a job has been generated. The job takes a little while to process.
The job’s tracking can be seen by clicking on the loading icon. The system will notify of any failures.
When the job is finished, in AWX, the boxes for each step in Ansible will turn green.
To display the WordPress endpoint, click on the box for the last step (“wordpress deployment”). Note that the Variables are the input and the Artifact (wordpress_endpoint) is the output.
We should now be able to display the artifact in the Abiquo. Click on the green check mark next to the workflow. (if it doesn’t appear, click the round refresh arrow in the top right corner of the screen, and if necessary, wait a few minutes).
In the Results dialog, the platform displays the IP address of your new WordPress instance.
You can also access the VMs on the myCloud tab in the Virtual appliances pane.
To display the VMs, click Open.
To open your new WordPress site, go to the IP address output by the service in the artifact.