Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
configuration
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
configuration
Commits
e9b122d9
Commit
e9b122d9
authored
Feb 14, 2014
by
Feanil Patel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update the create_user play to allow creating users without sudo access.
parent
8f4a3094
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
1 deletions
+13
-1
playbooks/edx-east/create_user.yml
+13
-1
No files found.
playbooks/edx-east/create_user.yml
View file @
e9b122d9
# Creates a single user on a server
# By default no super-user privileges
# Example: ansible-playbook -i "jarv.m.sandbox.edx.org," ./create_user.yml -e "user=jarv"
# Create a user with sudo privileges
# Example: ansible-playbook -i "jarv.m.sandbox.edx.org," ./create_user.yml -e "user=jarv" -e "give_sudo=true"
-
name
:
Create a single user
hosts
:
all
sudo
:
True
gather_facts
:
False
vars
:
give_sudo
:
False
pre_tasks
:
-
fail
:
msg="You must pass a user into this play"
when
:
not user
-
set_fact
:
-
name
:
give access with no sudo
set_fact
:
gh_users_no_sudo
:
-
"
{{
user
}}"
when
:
not give_sudo or give_sudo == "false"
-
name
:
give access with sudo
set_fact
:
gh_users
:
-
"
{{
user
}}"
when
:
give_sudo
roles
:
-
gh_users
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment