1,760
edits
Changes
→Part 2: A playbook to install and start Apache Server
<pre>
---
- hosts: 192.168.9949.1533 user: rootrchan become: yes
vars:
apache_version: 2.6
motd_warning: 'WARNING: use by ICT ITAS faculty/students only.'
testserver: yes
tasks:
Sample Run:
<pre>
[rchan@centos7 playbookshost ansible]$ ansible-playbook httpd-play.yml
PLAY [192.168.9949.1533] **********************************************************************
TASK [Gathering Facts] *******************************************************************ok: [192.168.9949.1533]
TASK [install apache] ********************************************************************changed: [192.168.9949.1533]
TASK [restart apache] ********************************************************************changed: [192.168.9949.1533]
PLAY RECAP *******************************************************************************192.168.9949.153 3 : ok=3 changed=2 unreachable=0 failed=0 skipped=0 rescued=0 ignored=0
</pre>
= Investigation III: Using Playbook to config a OPS435 Linux machine =
: You have just installed the latest version of CentOS 7.x on a VM with GNOME Desktop. You need to configure it so that you can use it for doing the Labs for OPS435. The following configuration need to be done on that VM: