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
f899f2e6
Commit
f899f2e6
authored
Jul 10, 2017
by
asadiqbal
Committed by
Douglas Hall
Jul 28, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ENT-322 enterprise_worker user
parent
ff55556e
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
0 deletions
+29
-0
playbooks/roles/common_vars/defaults/main.yml
+2
-0
playbooks/roles/edxapp/defaults/main.yml
+8
-0
playbooks/roles/edxapp/tasks/deploy.yml
+19
-0
No files found.
playbooks/roles/common_vars/defaults/main.yml
View file @
f899f2e6
...
...
@@ -221,3 +221,5 @@ COMMON_JWT_AUDIENCE: 'SET-ME-PLEASE'
COMMON_JWT_ISSUER
:
'
{{
COMMON_OIDC_ISSUER
}}'
COMMON_JWT_SECRET_KEY
:
'
SET-ME-PLEASE'
# Set worker user default
CREATE_SERVICE_WORKER_USERS
:
True
playbooks/roles/edxapp/defaults/main.yml
View file @
f899f2e6
...
...
@@ -697,6 +697,7 @@ EDXAPP_BLOCK_STRUCTURES_SETTINGS:
# Configuration settings needed for the LMS to communicate with the Enterprise service.
EDXAPP_ENTERPRISE_API_URL
:
"
{{
EDXAPP_LMS_ROOT_URL
}}/enterprise/api/v1"
EDXAPP_ENTERPRISE_SERVICE_WORKER_EMAIL
:
"
enterprise_worker@example.com"
EDXAPP_ENTERPRISE_SERVICE_WORKER_USERNAME
:
"
enterprise_worker"
EDXAPP_ENTERPRISE_COURSE_ENROLLMENT_AUDIT_MODES
:
...
...
@@ -1312,3 +1313,10 @@ edxapp_cms_variant: cms
# Worker Settings
worker_django_settings_module
:
'
{{
EDXAPP_SETTINGS
}}'
# Add default service worker users
SERVICE_WORKER_USERS
:
-
email
:
"
{{
EDXAPP_ENTERPRISE_SERVICE_WORKER_EMAIL
}}"
username
:
"
{{
EDXAPP_ENTERPRISE_SERVICE_WORKER_USERNAME
}}"
is_staff
:
true
is_superuser
:
false
playbooks/roles/edxapp/tasks/deploy.yml
View file @
f899f2e6
...
...
@@ -417,3 +417,22 @@
become_user
:
"
{{
common_web_user
}}"
tags
:
-
manage
-
name
:
build service worker users list
set_fact
:
service_worker_users
:
"
{{
[SERVICE_WORKER_USERS]
}}"
when
:
CREATE_SERVICE_WORKER_USERS
tags
:
-
manage
-
manage:db
-
name
:
create service worker users
shell
:
"
{{
edxapp_venv_bin
}}/python
./manage.py
lms
--settings={{
edxapp_settings
}}
--service-variant
lms
manage_user
{{
item.username}}
{{
item.email
}}
--unusable-password
{%
if
item.is_staff
%}
--staff{%
endif
%}"
args
:
chdir
:
"
{{
edxapp_code_dir
}}"
become_user
:
"
{{
common_web_user
}}"
with_items
:
"
{{
service_worker_users
}}"
when
:
CREATE_SERVICE_WORKER_USERS
tags
:
-
manage
-
manage:db
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