Showing
1 changed file
with
17 additions
and
6 deletions
1 | -- hosts: order, promotion | ||
2 | - vars_prompt: | ||
3 | - - name: "confirmation" | ||
4 | - prompt: "Please Enter YES to continue." | ||
5 | - private: no | 1 | +- hosts: order |
6 | vars: | 2 | vars: |
7 | gw_url: 10.66.70.79:8080/gateway | 3 | gw_url: 10.66.70.79:8080/gateway |
8 | tasks: | 4 | tasks: |
@@ -12,4 +8,19 @@ | @@ -12,4 +8,19 @@ | ||
12 | when: confirmation != 'YES' | 8 | when: confirmation != 'YES' |
13 | - uri: | 9 | - uri: |
14 | url: http://{{gw_url}}/service_control/unregister?ip={{inventory_hostname}}&context={{group_names[0]}} | 10 | url: http://{{gw_url}}/service_control/unregister?ip={{inventory_hostname}}&context={{group_names[0]}} |
15 | - remote_user: root | ||
11 | + remote_user: root | ||
12 | + | ||
13 | + | ||
14 | +- hosts: promotion | ||
15 | + vars: | ||
16 | + gw_url: 10.66.70.79:8080/gateway | ||
17 | + tasks: | ||
18 | + - name: "make sure user type yes to confirm" | ||
19 | + fail: | ||
20 | + msg: "user do not type yes" | ||
21 | + when: confirmation != 'YES' | ||
22 | + - uri: | ||
23 | + url: http://{{gw_url}}/service_control/unregister?ip={{inventory_hostname}}&context={{group_names[0]}} | ||
24 | + remote_user: root | ||
25 | + | ||
26 | + |
-
Please register or login to post a comment