Ansible

7 posts

Ansible – A playbook for setting up an apache webserver

Here’s a simple playbook that set’s up an apache webserver: [root@controller playbooks]# pwd /root/playbooks [root@controller playbooks]# cat httpd.yaml — – name: This sets up an httpd webserver hosts: ansibleclient01.local tasks: – name: Install the httpd rpm yum: name=httpd – name: start the httpd service service: name=httpd state=started – name: Open […]Read more »

Ansible – Installing Ansible

There are a few of ways to install ansible. For the rest of these articles I’ll be running Ansible on Centos 7. Install Ansible using yum This is done like this: $ yum install epel-release $ yum install ansible Then check the version of ansible installed: $ ansible –version It […]Read more »

Ansible – A “hello world” Playbook

Playbooks are written in yaml format, and you can actually choose where to store your playbooks. In my case I’ll create a folder called “playbooks” for storing my playbooks, and I’ll create this in the root user’s home directory:   [root@controller ~]# pwd /root [root@controller ~]# mkdir playbooks [root@controller ~]# […]Read more »

Ansible – About this Course

What is Ansible Ansible can be thought of as general purpose tool for managing servers. This means that Ansible can be used as a: Server provisioning tool – build new vm, e.g. in aws. Ansible can also do orchestration, i.e. build+configure servers in a specific sequence. Ansible has a number […]Read more »