Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
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
edx-platform
Commits
dcb77ff7
Unverified
Commit
dcb77ff7
authored
Nov 23, 2017
by
Matjaz Gregoric
Committed by
GitHub
Nov 23, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #16510 from open-craft/mtyaka/lms-internal-root-url
Introduce LMS_INTERNAL_ROOT_URL.
parents
705aac79
d403e5f8
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
22 additions
and
14 deletions
+22
-14
cms/envs/aws.py
+3
-0
cms/envs/common.py
+3
-2
lms/envs/aws.py
+6
-5
lms/envs/common.py
+5
-4
lms/envs/devstack.py
+2
-1
lms/envs/devstack_docker.py
+2
-1
requirements/edx/base.txt
+1
-1
No files found.
cms/envs/aws.py
View file @
dcb77ff7
...
...
@@ -138,6 +138,9 @@ EMAIL_USE_TLS = ENV_TOKENS.get('EMAIL_USE_TLS', EMAIL_USE_TLS)
LMS_BASE
=
ENV_TOKENS
.
get
(
'LMS_BASE'
)
LMS_ROOT_URL
=
ENV_TOKENS
.
get
(
'LMS_ROOT_URL'
)
LMS_INTERNAL_ROOT_URL
=
ENV_TOKENS
.
get
(
'LMS_INTERNAL_ROOT_URL'
,
LMS_ROOT_URL
)
ENTERPRISE_API_URL
=
ENV_TOKENS
.
get
(
'ENTERPRISE_API_URL'
,
LMS_INTERNAL_ROOT_URL
+
'/enterprise/api/v1/'
)
ENTERPRISE_CONSENT_API_URL
=
ENV_TOKENS
.
get
(
'ENTERPRISE_CONSENT_API_URL'
,
LMS_INTERNAL_ROOT_URL
+
'/consent/api/v1/'
)
# Note that FEATURES['PREVIEW_LMS_BASE'] gets read in from the environment file.
SITE_NAME
=
ENV_TOKENS
[
'SITE_NAME'
]
...
...
cms/envs/common.py
View file @
dcb77ff7
...
...
@@ -378,9 +378,10 @@ AUTHENTICATION_BACKENDS = [
LMS_BASE
=
None
LMS_ROOT_URL
=
"http://localhost:8000"
LMS_INTERNAL_ROOT_URL
=
LMS_ROOT_URL
LMS_ENROLLMENT_API_PATH
=
"/api/enrollment/v1/"
ENTERPRISE_API_URL
=
LMS_ROOT_URL
+
'/enterprise/api/v1/'
ENTERPRISE_CONSENT_API_URL
=
LMS_ROOT_URL
+
'/consent/api/v1/'
ENTERPRISE_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
'/enterprise/api/v1/'
ENTERPRISE_CONSENT_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
'/consent/api/v1/'
# These are standard regexes for pulling out info like course_ids, usage_ids, etc.
# They are used so that URLs with deprecated-format strings still work.
...
...
lms/envs/aws.py
View file @
dcb77ff7
...
...
@@ -185,6 +185,7 @@ EDXMKTG_LOGGED_IN_COOKIE_NAME = ENV_TOKENS.get('EDXMKTG_LOGGED_IN_COOKIE_NAME',
EDXMKTG_USER_INFO_COOKIE_NAME
=
ENV_TOKENS
.
get
(
'EDXMKTG_USER_INFO_COOKIE_NAME'
,
EDXMKTG_USER_INFO_COOKIE_NAME
)
LMS_ROOT_URL
=
ENV_TOKENS
.
get
(
'LMS_ROOT_URL'
)
LMS_INTERNAL_ROOT_URL
=
ENV_TOKENS
.
get
(
'LMS_INTERNAL_ROOT_URL'
,
LMS_ROOT_URL
)
ENV_FEATURES
=
ENV_TOKENS
.
get
(
'FEATURES'
,
{})
for
feature
,
value
in
ENV_FEATURES
.
items
():
...
...
@@ -958,7 +959,7 @@ ENTERPRISE_PUBLIC_ENROLLMENT_API_URL = ENV_TOKENS.get(
# Enrollment URL used on the server-side.
ENTERPRISE_ENROLLMENT_API_URL
=
ENV_TOKENS
.
get
(
'ENTERPRISE_ENROLLMENT_API_URL'
,
ENTERPRISE_ENROLLMENT_API_URL
(
LMS_INTERNAL_ROOT_URL
or
''
)
+
LMS_ENROLLMENT_API_PATH
)
# Enterprise logo image size limit in KB's
...
...
@@ -994,13 +995,13 @@ ENTERPRISE_REPORTING_SECRET = AUTH_TOKENS.get(
# the service, and override the default parameters which are defined in common.py
DEFAULT_ENTERPRISE_API_URL
=
None
if
LMS_ROOT_URL
is
not
None
:
DEFAULT_ENTERPRISE_API_URL
=
LMS_ROOT_URL
+
'/enterprise/api/v1/'
if
LMS_
INTERNAL_
ROOT_URL
is
not
None
:
DEFAULT_ENTERPRISE_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
'/enterprise/api/v1/'
ENTERPRISE_API_URL
=
ENV_TOKENS
.
get
(
'ENTERPRISE_API_URL'
,
DEFAULT_ENTERPRISE_API_URL
)
DEFAULT_ENTERPRISE_CONSENT_API_URL
=
None
if
LMS_ROOT_URL
is
not
None
:
DEFAULT_ENTERPRISE_CONSENT_API_URL
=
LMS_ROOT_URL
+
'/consent/api/v1/'
if
LMS_
INTERNAL_
ROOT_URL
is
not
None
:
DEFAULT_ENTERPRISE_CONSENT_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
'/consent/api/v1/'
ENTERPRISE_CONSENT_API_URL
=
ENV_TOKENS
.
get
(
'ENTERPRISE_CONSENT_API_URL'
,
DEFAULT_ENTERPRISE_CONSENT_API_URL
)
ENTERPRISE_SERVICE_WORKER_USERNAME
=
ENV_TOKENS
.
get
(
...
...
lms/envs/common.py
View file @
dcb77ff7
...
...
@@ -65,6 +65,7 @@ DISCUSSION_SETTINGS = {
}
LMS_ROOT_URL
=
"http://localhost:8000"
LMS_INTERNAL_ROOT_URL
=
LMS_ROOT_URL
LMS_ENROLLMENT_API_PATH
=
"/api/enrollment/v1/"
# Features
...
...
@@ -3325,8 +3326,8 @@ derived('HELP_TOKENS_LANGUAGE_CODE', 'HELP_TOKENS_VERSION')
#
# Only used if FEATURES['ENABLE_ENTERPRISE_INTEGRATION'] == True.
ENTERPRISE_ENROLLMENT_API_URL
=
LMS_ROOT_URL
+
LMS_ENROLLMENT_API_PATH
ENTERPRISE_PUBLIC_ENROLLMENT_API_URL
=
ENTERPRISE_ENROLLMENT_API_URL
ENTERPRISE_ENROLLMENT_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
LMS_ENROLLMENT_API_PATH
ENTERPRISE_PUBLIC_ENROLLMENT_API_URL
=
LMS_ROOT_URL
+
LMS_ENROLLMENT_API_PATH
ENTERPRISE_COURSE_ENROLLMENT_AUDIT_MODES
=
[
'audit'
,
'honor'
]
ENTERPRISE_SUPPORT_URL
=
''
# The default value of this needs to be a 16 character string
...
...
@@ -3337,8 +3338,8 @@ ENTERPRISE_REPORTING_SECRET = '0000000000000000'
# These default settings are utilized by the LMS when interacting with the service,
# and are overridden by the configuration parameter accessors defined in aws.py
ENTERPRISE_API_URL
=
LMS_ROOT_URL
+
'/enterprise/api/v1/'
ENTERPRISE_CONSENT_API_URL
=
LMS_ROOT_URL
+
'/consent/api/v1/'
ENTERPRISE_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
'/enterprise/api/v1/'
ENTERPRISE_CONSENT_API_URL
=
LMS_
INTERNAL_
ROOT_URL
+
'/consent/api/v1/'
ENTERPRISE_SERVICE_WORKER_USERNAME
=
'enterprise_worker'
ENTERPRISE_API_CACHE_TIMEOUT
=
3600
# Value is in seconds
ENTERPRISE_CUSTOMER_LOGO_IMAGE_SIZE
=
512
# Enterprise logo image size limit in KB's
...
...
lms/envs/devstack.py
View file @
dcb77ff7
...
...
@@ -20,7 +20,8 @@ CELERY_ALWAYS_EAGER = True
HTTPS
=
'off'
LMS_ROOT_URL
=
'http://localhost:8000'
ENTERPRISE_API_URL
=
LMS_ROOT_URL
+
'/enterprise/api/v1/'
LMS_INTERNAL_ROOT_URL
=
LMS_ROOT_URL
ENTERPRISE_API_URL
=
LMS_INTERNAL_ROOT_URL
+
'/enterprise/api/v1/'
################################ LOGGERS ######################################
...
...
lms/envs/devstack_docker.py
View file @
dcb77ff7
...
...
@@ -13,13 +13,14 @@ LMS_BASE = 'edx.devstack.lms:18000'
CMS_BASE
=
'edx.devstack.studio:18010'
SITE_NAME
=
LMS_BASE
LMS_ROOT_URL
=
'http://{}'
.
format
(
LMS_BASE
)
LMS_INTERNAL_ROOT_URL
=
LMS_ROOT_URL
ECOMMERCE_PUBLIC_URL_ROOT
=
'http://localhost:18130'
ECOMMERCE_API_URL
=
'http://edx.devstack.ecommerce:18130/api/v2'
COMMENTS_SERVICE_URL
=
'http://edx.devstack.forum:4567'
ENTERPRISE_API_URL
=
'{}/enterprise/api/v1/'
.
format
(
LMS_ROOT_URL
)
ENTERPRISE_API_URL
=
'{}/enterprise/api/v1/'
.
format
(
LMS_
INTERNAL_
ROOT_URL
)
CREDENTIALS_INTERNAL_SERVICE_URL
=
'http://edx.devstack.credentials:18150'
CREDENTIALS_PUBLIC_SERVICE_URL
=
'http://localhost:18150'
...
...
requirements/edx/base.txt
View file @
dcb77ff7
...
...
@@ -47,7 +47,7 @@ edx-lint==0.4.3
astroid==1.3.8
edx-django-oauth2-provider==1.2.5
edx-django-sites-extensions==2.3.0
edx-enterprise==0.53.1
5
edx-enterprise==0.53.1
6
edx-oauth2-provider==1.2.2
edx-opaque-keys==0.4.0
edx-organizations==0.4.8
...
...
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