httpd_webserver

Ansible-Httpd-Role

Lets understand the Problem Statement:

  1. Create an Ansible Role to install Apache Httpd Software on Remote system.
  2. Deploy Static WebPages on webserver inside /var/www/html folder.
  3. Start Httpd webserver and make httpd Service permanent on reboot.
  4. Add Idempotence to Httpd such that on new Webpage Deploy, Webserver restarts automatically.

To replicate same setup on your Local Machine perform following steps:

  • Install Ansible on local system and this local machine acts as Master Node.
  • Clone this repository on Local Machine and edit ansible.cfg file to add up location where our Role is present using roles_path keyword.
  • Now create Inventory File and Playbook for running this role.Specify Inventory Location in Inventory using inventory.
  • Copy WebPage you like to deploy on webserver to Ansible-Httpd-Role/files/ and edit Ansible-Httpd-Role/vars/main.yml to tell about webpage.
  • Go Inside Ansible-Httpd-Role/vars/main.yml folder and edit web_page_deploy given variable to tell about New WebPage.

Finally all things set so it's time to Deploy above complete setup and run below command:

ansible-playbook

Detailed Article: Ansible-Httpd-Role Article

About

An Ansible Role to setup Apache HTTPD webserver.

Install
ansible-galaxy install shubhambhardwaj007/Ansible-Httpd-Role
GitHub repository
License
Unknown
Downloads
22
Owner
Cybersecurity researcher | Hybrid Multi Cloud | Openstack | AWS EKS | DevOps | Docker | Kubernetes | Jenkins |AWS | Terraform