-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathnginx_controller_user.yaml
43 lines (39 loc) · 1.35 KB
/
nginx_controller_user.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
---
# ansible-playbook nginx_controller_user.yaml -i controller -e "[email protected] nginx_controller_password=userPassword"
# add users to nginx Controller
- hosts: localhost
tasks:
- name: Retrieve the NGINX Controller auth token
include_role:
name: nginxinc.nginx_controller_generate_token
# Define one user account
- name: Configure the user
include_role:
name: nginxinc.nginx_controller_user
vars:
nginx_controller_user:
metadata:
name: "[email protected]"
displayName: "contractor george"
description: "the account of george"
tags:
- "contractors"
desiredState:
firstName: George
lastName: Jungle
password: "Apes ar3 cute"
roles:
- ref: "platform/roles/user"
# groups: # 3.7 reference(s) to security Groups the user is a member of
# - ref:
# # Define an array of user accounts
# - name: read the user array
# include_vars:
# file: "nginx_controller_user_vars.yaml"
# name: users
# - name: Configure array of users
# include_role:
# name: nginxinc.nginx_controller_user
# vars:
# nginx_controller_user: "{{ item }}"
# with_items: "{{ users.users }}"