DevOps Articles

Curated articles, resources, tips and trends from the DevOps World.

Ansible — Automate Docker and httpd

4 years ago medium.com

Summary: This is a summary of an article originally published by the source. Read the full original article here →

This post will briefly explain the how to use Ansible to automate the deployment of docker and kick-off a webserver. Ansible playbook for to perform the following steps in the managed nodes. Configure Docker- Start and enable Docker services- Pull the httpd server image from the Docker Hub- Run the httpd container and expose it to the public- Copy the html code in /var/www/html directory and start the web server

Managed nodes are configured here: /etc/.txt (Example: /etc/hosts.txt)

To check the connectivity with managed nodes: ansible all -m ping

Made with pure grit © 2024 Jetpack Labs Inc. All rights reserved. www.jetpacklabs.com