Skip to content

Commit f6cf6ee

Browse files
authored
Merge pull request #764 from ansible/devel
April 2nd, 2020 release PR
2 parents 52d2a67 + 33c83d3 commit f6cf6ee

File tree

153 files changed

+2964
-916
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

153 files changed

+2964
-916
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ ansible/
1919
*.retry
2020
demos/servicenow/private.yml
2121
*.html
22+
!exercises/ansible_rhel/1.3-playbook/index.html
2223
demos/servicenow/closed_loop_incident_mgmt/input_vars.yaml
2324
demos/servicenow/closed_loop_incident_mgmt/snow_demo2/snow_vars.yaml
2425
provisioner/roles/ansible_security.ids_config/

bindep.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
sshpass [epel]

exercises/ansible_f5/1.0-explore/README.ja.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,14 +80,14 @@ f5 ansible_host=34.199.128.69 ansible_user=admin private_ip=172.16.26.136 ansibl
8080
[control]
8181
ansible ansible_host=107.23.192.217 ansible_user=ec2-user private_ip=172.16.207.49
8282
83-
[webservers]
84-
host1 ansible_host=107.22.141.4 ansible_user=ec2-user private_ip=172.16.170.190
85-
host2 ansible_host=54.146.162.192 ansible_user=ec2-user private_ip=172.16.160.13
83+
[web]
84+
node1 ansible_host=107.22.141.4 ansible_user=ec2-user private_ip=172.16.170.190
85+
node2 ansible_host=54.146.162.192 ansible_user=ec2-user private_ip=172.16.160.13
8686
```
8787

8888
#### Step 5
8989

90-
上の出力では `[ ]` でグループを定義しています。例えば `[webservers]``host1``host2` を含んむグループです。
90+
上の出力では `[ ]` でグループを定義しています。例えば `[web]``node1``node2` を含んむグループです。
9191

9292
> Note: **all** というグループは常に存在し、インベントリー内で定義された全てのホストとグループを含みます。
9393

exercises/ansible_f5/1.2-add-node/README.ja.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767
password: "{{ansible_ssh_pass}}"
6868
server_port: "8443"
6969
validate_certs: "no"
70-
loop: "{{ groups['webservers'] }}"
70+
loop: "{{ groups['web'] }}"
7171
```
7272
{% endraw %}
7373

@@ -81,9 +81,9 @@
8181
- `password: "{{ansible_ssh_pass}}"` : BIG-IPへログインする際のパスワードを指定します。
8282
- `server_port: 8443` : BIG-IPへ接続する際のポート番号を指定します。
8383
- `host: "{{hostvars[item].ansible_host}}"` : モジュールへインベントリに登録済みのWebサーバーのIPアドレスを追加します。
84-
- `name: "{{hostvars[item].inventory_hostname}}"` : `inventory_hostname` をホスト名(host1、host2 となります)として使うことを指示します。
84+
- `name: "{{hostvars[item].inventory_hostname}}"` : `inventory_hostname` をホスト名(node1、node2 となります)として使うことを指示します。
8585
- `validate_certs: "no"` : (あくまで演習用ラボなので)SSL証明書の検証を行わないように設定します。
86-
- `loop:` : 与えられた一覧に対してタスクをループ実行することを指定します。この演習では、二つのRHELホストを含む webservers グループが一覧となります。
86+
- `loop:` : 与えられた一覧に対してタスクをループ実行することを指定します。この演習では、二つのRHELホストを含む web グループが一覧となります。
8787

8888
## Step 4
8989

@@ -103,8 +103,8 @@
103103
PLAY [BIG-IP SETUP] ************************************************************
104104
105105
TASK [CREATE NODES] ************************************************************
106-
changed: [f5] => (item=host1)
107-
changed: [f5] => (item=host2)
106+
changed: [f5] => (item=node1)
107+
changed: [f5] => (item=node2)
108108
109109
PLAY RECAP *********************************************************************
110110
f5 : ok=1 changed=1 unreachable=0 failed=0

exercises/ansible_f5/1.2-add-node/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ Next, append the first `task` to above playbook. This task will use the `bigip_n
6262
validate_certs: no
6363
host: "{{hostvars[item].ansible_host}}"
6464
name: "{{hostvars[item].inventory_hostname}}"
65-
loop: "{{ groups['webservers'] }}"
65+
loop: "{{ groups['web'] }}"
6666
```
6767
<!-- {% endraw %} -->
6868

@@ -76,9 +76,9 @@ Next, append the first `task` to above playbook. This task will use the `bigip_n
7676
- The `password: "{{ansible_ssh_pass}}"` parameter tells the module the password to login to the F5 BIG-IP device with
7777
- The `server_port: 8443` parameter tells the module the port to connect to the F5 BIG-IP device with
7878
- The `host: "{{hostvars[item].ansible_host}}"` parameter tells the module to add a web server IP address already defined in our inventory.
79-
- The `name: "{{hostvars[item].inventory_hostname}}"` parameter tells the module to use the `inventory_hostname` as the name (which will be host1 and host2).
79+
- The `name: "{{hostvars[item].inventory_hostname}}"` parameter tells the module to use the `inventory_hostname` as the name (which will be node1 and node2).
8080
- The `validate_certs: "no"` parameter tells the module to not validate SSL certificates. This is just used for demonstration purposes since this is a lab.
81-
- `loop:` tells the task to loop over the provided list. The list in this case is the group webservers which includes two RHEL hosts.
81+
- `loop:` tells the task to loop over the provided list. The list in this case is the group web which includes two RHEL hosts.
8282

8383
Save the file and exit out of editor.
8484

@@ -100,8 +100,8 @@ The output will look as follows.
100100
PLAY [BIG-IP SETUP] ************************************************************
101101
102102
TASK [CREATE NODES] ************************************************************
103-
changed: [f5] => (item=host1)
104-
changed: [f5] => (item=host2)
103+
changed: [f5] => (item=node1)
104+
changed: [f5] => (item=node2)
105105
106106
PLAY RECAP *********************************************************************
107107
f5 : ok=1 changed=1 unreachable=0 failed=0

exercises/ansible_f5/1.2-add-node/bigip-node.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@
1616
validate_certs: false
1717
host: "{{hostvars[item].ansible_host}}"
1818
name: "{{hostvars[item].inventory_hostname}}"
19-
loop: "{{ groups['webservers'] }}"
19+
loop: "{{ groups['web'] }}"

exercises/ansible_f5/1.4-add-pool-members/README.ja.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@
6868
password: "{{ansible_ssh_pass}}"
6969
server_port: "8443"
7070
validate_certs: "no"
71-
loop: "{{ groups['webservers'] }}"
71+
loop: "{{ groups['web'] }}"
7272
```
7373
{% endraw %}
7474

@@ -80,13 +80,13 @@
8080
- `password: "{{ansible_ssh_pass}}"` : BIG-IPへログインする際のパスワードを指定します。
8181
- `server_port: 8443` : BIG-IPへ接続する際のポート番号を指定します。
8282
- `state: "present"` : プールメンバーを(削除ではなく)追加するように指定します。
83-
- `name: "{{hostvars[item].inventory_hostname}}"` parameter tells the module to use the `inventory_hostname` as the name (which will be host1 and host2).
84-
- `name: "{{hostvars[item].inventory_hostname}}"``inventory_hostname` をホスト名(host1、host2 となります)として使うことを指示します。
83+
- `name: "{{hostvars[item].inventory_hostname}}"` parameter tells the module to use the `inventory_hostname` as the name (which will be node1 and node2).
84+
- `name: "{{hostvars[item].inventory_hostname}}"``inventory_hostname` をホスト名(node1、node2 となります)として使うことを指示します。
8585
- `host: "{{hostvars[item].ansible_host}}"` : モジュールへインベントリに登録済みのWebサーバーのIPアドレスを追加します。
8686
- `pool: "http_pool"` : Webサーバーを追加するプールとして、http_pool を指定します。
8787
- `validate_certs: "no"` : (あくまで演習用ラボなので)SSL証明書の検証を行わないように設定します。
8888
最後に、(モジュール・パラメータではなく)タスクレベルのパラメータである、loop パラメータの指定です。
89-
- `loop:` : 与えられた一覧に対してタスクをループ実行することを指定します。この演習では、二つのRHELホストを含む webservers グループが一覧となります。
89+
- `loop:` : 与えられた一覧に対してタスクをループ実行することを指定します。この演習では、二つのRHELホストを含む web グループが一覧となります。
9090

9191
## Step 4
9292

@@ -106,8 +106,8 @@
106106
PLAY [BIG-IP SETUP] ************************************************************
107107
108108
TASK [ADD POOL MEMBERS] ********************************************************
109-
changed: [f5] => (item=host1)
110-
changed: [f5] => (item=host2)
109+
changed: [f5] => (item=node1)
110+
changed: [f5] => (item=node2)
111111
112112
PLAY RECAP *********************************************************************
113113
f5 : ok=1 changed=1 unreachable=0 failed=0
@@ -173,11 +173,11 @@ TASK [Query BIG-IP facts] ******************************************************
173173
changed: [f5]
174174
175175
TASK [Show members belonging to pool] ***********************************************************************************************************************
176-
ok: [f5] => (item=host1:80) => {
177-
"msg": "host1:80"
176+
ok: [f5] => (item=node1:80) => {
177+
"msg": "node1:80"
178178
}
179-
ok: [f5] => (item=host2:80) => {
180-
"msg": "host2:80"
179+
ok: [f5] => (item=node2:80) => {
180+
"msg": "node2:80"
181181
}
182182
183183
PLAY RECAP **************************************************************************************************************************************************
@@ -209,7 +209,7 @@ BIG-IP へのログイン情報:
209209
- username: admin
210210
- password: admin
211211

212-
プールに二つのメンバー(host1とhost2)が含まれていることを確認します。Local Traffic -> Pools とクリックします。そして、http_pool をクリックすることでより詳細な情報を確認します。Members タブをクリックすることで全てのプールメンバーが表示されます。
212+
プールに二つのメンバー(node1とnode2)が含まれていることを確認します。Local Traffic -> Pools とクリックします。そして、http_pool をクリックすることでより詳細な情報を確認します。Members タブをクリックすることで全てのプールメンバーが表示されます。
213213
![f5members](poolmembers.png)
214214

215215

exercises/ansible_f5/1.4-add-pool-members/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ Next, append the first `task` to above playbook. This task will use the `bigip_p
6565
host: "{{hostvars[item].ansible_host}}"
6666
port: "80"
6767
pool: "http_pool"
68-
loop: "{{ groups['webservers'] }}"
68+
loop: "{{ groups['web'] }}"
6969
```
7070
{% endraw %}
7171

@@ -87,7 +87,7 @@ Next we have module parameters
8787
- The `pool: "http_pool"` parameter tells the module to put this node into a pool named http_pool
8888
- The `validate_certs: "no"` parameter tells the module to not validate SSL certificates. This is just used for demonstration purposes since this is a lab.
8989
Finally there is a loop parameter which is at the task level (it is not a module parameter but a task level parameter:
90-
- `loop:` tells the task to loop over the provided list. The list in this case is the group webservers which includes two RHEL hosts.
90+
- `loop:` tells the task to loop over the provided list. The list in this case is the group web which includes two RHEL hosts.
9191

9292
Save the file and exit out of editor.
9393

exercises/ansible_f5/1.4-add-pool-members/bigip-pool-members.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,4 @@
1919
host: "{{hostvars[item].ansible_host}}"
2020
port: "80"
2121
pool: "http_pool"
22-
loop: "{{ groups['webservers'] }}"
22+
loop: "{{ groups['web'] }}"

exercises/ansible_f5/1.5-add-virtual-server/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ Each RHEL web server actually already has apache running. Exercise 1.1 through
139139

140140
>This time use port 443 instead of 8443, e.g. https://X.X.X.X:443/
141141

142-
Each time you refresh the host will change between **host1** and **host2**. Here is animation of the host field changing:
142+
Each time you refresh the host will change between **node1** and **node2**. Here is animation of the host field changing:
143143
![animation](animation.gif)
144144
>the animation might not work on certain browsers
145145

@@ -149,11 +149,11 @@ Instead of using a browser window it is also possible to use the command line on
149149

150150
```
151151
[studentX@ansible ~]$ curl https://172.16.26.136:443 --insecure --silent | grep studentX
152-
<p>F5TEST-studentX-host1</p>
152+
<p>F5TEST-studentX-node1</p>
153153
[studentX@ansible ~]$ curl https://172.16.26.136:443 --insecure --silent | grep studentX
154-
<p>F5TEST-studentX-host2</p>
154+
<p>F5TEST-studentX-node2</p>
155155
[studentX@ansible ~]$ curl https://172.16.26.136:443 --insecure --silent | grep studentX
156-
<p>F5TEST-studentX-host1</p>
156+
<p>F5TEST-studentX-node1</p>
157157
```
158158
159159

exercises/ansible_f5/1.6-add-irules/README.ja.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ when HTTP_REQUEST {
8484
irules: ['irule1','irule2']
8585
8686
tasks:
87-
87+
8888
- name: ADD iRules
8989
bigip_irule:
9090
provider:

exercises/ansible_f5/1.6-add-irules/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ Next, append the `task` to above playbook. This task will use the `bigip_virtual
122122
{% raw %}
123123
``` yaml
124124

125-
125+
126126
- name: ATTACH iRules TO VIRTUAL SERVER
127127
bigip_virtual_server:
128128
provider:

exercises/ansible_f5/2.0-disable-pool-member/README.ja.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -173,24 +173,24 @@ ok: [f5] => (item=None)
173173
ok: [f5]
174174

175175
TASK [Show members belonging to pool http_pool] *************************************************************************************************************
176-
ok: [f5] => (item=host1:80) => {
177-
"msg": "host1:80"
176+
ok: [f5] => (item=node1:80) => {
177+
"msg": "node1:80"
178178
}
179-
ok: [f5] => (item=host2:80) => {
180-
"msg": "host2:80"
179+
ok: [f5] => (item=node2:80) => {
180+
"msg": "node2:80"
181181
}
182182

183183
TASK [pause] ************************************************************************************************************
184184
[pause]
185185
To disable a particular member enter member with format member_name:port
186186
To disable all members of the pool enter 'all':
187-
host1:80
187+
node1:80
188188

189189
TASK [Disable ALL pool members] ************************************************************************************************************************
190-
skipping: [f5] => (item=host1:80)
191-
skipping: [f5] => (item=host2:80)
190+
skipping: [f5] => (item=node1:80)
191+
skipping: [f5] => (item=node2:80)
192192

193-
TASK [Disable pool member host1:80] *************************************************************************************************************************
193+
TASK [Disable pool member node1:80] *************************************************************************************************************************
194194
changed: [f5]
195195

196196
PLAY RECAP **************************************************************************************************************

exercises/ansible_f5/2.1-delete-configuration/README.ja.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,8 +208,8 @@ TASK [DELETE POOL] *************************************************************
208208
changed: [f5]
209209

210210
TASK [DELETE NODES] *************************************************************************************************************************************
211-
changed: [f5] => (item=host1)
212-
changed: [f5] => (item=host2)
211+
changed: [f5] => (item=node1)
212+
changed: [f5] => (item=node2)
213213

214214
PLAY RECAP **************************************************************************************************************************************
215215
f5 : ok=4 changed=3 unreachable=0 failed=0

exercises/ansible_f5/2.1-delete-configuration/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ Finally, add the last `task` using the [bigip_node](https://docs.ansible.com/ans
148148
provider: "{{provider}}"
149149
name: "{{hostvars[item].inventory_hostname}}"
150150
state: absent
151-
loop: "{{ groups['webservers'] }}"
151+
loop: "{{ groups['web'] }}"
152152
```
153153
{% endraw %}
154154
The above playbook will delete the virtual server, then the pool and then the nodes configured in previous exercises.
@@ -181,8 +181,8 @@ TASK [DELETE POOL] *************************************************************
181181
changed: [f5]
182182

183183
TASK [DELETE NODES] *************************************************************************************************************************************
184-
changed: [f5] => (item=host1)
185-
changed: [f5] => (item=host2)
184+
changed: [f5] => (item=node1)
185+
changed: [f5] => (item=node2)
186186

187187
PLAY RECAP **************************************************************************************************************************************
188188
f5 : ok=4 changed=3 unreachable=0 failed=0

exercises/ansible_f5/2.1-delete-configuration/bigip-delete-configuration.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@
3131
provider: "{{provider}}"
3232
name: "{{hostvars[item].inventory_hostname}}"
3333
state: absent
34-
loop: "{{ groups['webservers'] }}"
34+
loop: "{{ groups['web'] }}"

0 commit comments

Comments
 (0)