Deploying the Ansible Code

Create a Docker container GitHub action and deploy the Ansible code.

Running Ansible within a release pipeline isn’t as easy as running a playbook. The build agents running your code are not configured to run Ansible. You are responsible for building that environment at runtime.

You already have the Ansible environment codified in a Dockerfile. Now the question becomes, "How do you run that container with GitHub actions?"

To accomplish this, you will create a Docker container GitHub action and a workflow that uses that action to deploy Ansible.

Create a Docker container GitHub action

Use the following Dockerfile to create the container that our release pipeline uses:

Multi Cloud Dockerfile
The Dockerfile contains all the tools and packages required to manage both Azure and AWS environments.

Get hands-on with 1200+ tech skills courses.