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
cfb1ec11
Commit
cfb1ec11
authored
Mar 11, 2015
by
David Baumgold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Define TENDER_SUBDOMAIN to that we can still use vanity URLs
parent
f473c474
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
13 additions
and
6 deletions
+13
-6
cms/envs/aws.py
+1
-0
cms/envs/common.py
+7
-2
cms/envs/test.py
+1
-0
cms/static/require-config.js
+2
-2
cms/templates/base.html
+1
-1
cms/templates/widgets/tender.html
+1
-1
No files found.
cms/envs/aws.py
View file @
cfb1ec11
...
...
@@ -200,6 +200,7 @@ LOGGING = get_logger_config(LOG_DIR,
PLATFORM_NAME
=
ENV_TOKENS
.
get
(
'PLATFORM_NAME'
,
'edX'
)
STUDIO_NAME
=
ENV_TOKENS
.
get
(
'STUDIO_NAME'
,
'edX Studio'
)
TENDER_DOMAIN
=
ENV_TOKENS
.
get
(
'TENDER_DOMAIN'
,
TENDER_DOMAIN
)
TENDER_SUBDOMAIN
=
ENV_TOKENS
.
get
(
'TENDER_SUBDOMAIN'
,
TENDER_SUBDOMAIN
)
# Event Tracking
if
"TRACKING_IGNORE_URL_PATTERNS"
in
ENV_TOKENS
:
...
...
cms/envs/common.py
View file @
cfb1ec11
...
...
@@ -577,8 +577,13 @@ REQUIRE_EXCLUDE = ("build.txt",)
REQUIRE_ENVIRONMENT
=
"node"
# If you want to enable Tender integration (http://tenderapp.com/),
# put in the domain where Tender hosts tender_widget.js. For example,
# TENDER_DOMAIN = "example.tenderapp.com"
# put in the subdomain where Tender hosts tender_widget.js. For example,
# if you want to use the URL https://example.tenderapp.com/tender_widget.js,
# you should use "example".
TENDER_SUBDOMAIN
=
None
# If you want to have a vanity domain that points to Tender, put that here.
# For example, "help.myapp.com". Otherwise, should should be your full
# tenderapp domain name: for example, "example.tenderapp.com".
TENDER_DOMAIN
=
None
################################# CELERY ######################################
...
...
cms/envs/test.py
View file @
cfb1ec11
...
...
@@ -91,6 +91,7 @@ STATIC_URL = "/static/"
PIPELINE_ENABLED
=
False
TENDER_DOMAIN
=
"help.edge.edx.org"
TENDER_SUBDOMAIN
=
"edxedge"
# Update module store settings per defaults for tests
update_module_store_settings
(
...
...
cms/static/require-config.js
View file @
cfb1ec11
...
...
@@ -67,9 +67,9 @@ require.config({
// externally hosted files
"tender"
:
[
// if TENDER_DOMAIN is defined, use that; otherwise, use a dummy value
// if TENDER_
SUB
DOMAIN is defined, use that; otherwise, use a dummy value
// (the application JS will never `require(['tender'])` if it's not defined)
"//"
+
(
typeof
TENDER_
DOMAIN
===
"string"
?
TENDER_DOMAIN
:
"api.tenderapp.com"
)
+
"
/tender_widget"
,
"//"
+
(
typeof
TENDER_
SUBDOMAIN
===
"string"
?
TENDER_SUBDOMAIN
:
"example"
)
+
".tenderapp.com
/tender_widget"
,
// if tender fails to load, fallback on a local file
// so that require doesn't fall over
"js/src/tender_fallback"
...
...
cms/templates/base.html
View file @
cfb1ec11
...
...
@@ -52,7 +52,7 @@ import json
<script
type=
"text/javascript"
>
window
.
baseUrl
=
$
{
json
.
dumps
(
settings
.
STATIC_URL
)};
window
.
TENDER_
DOMAIN
=
$
{
json
.
dumps
(
settings
.
TENDER_
DOMAIN
)};
window
.
TENDER_
SUBDOMAIN
=
$
{
json
.
dumps
(
settings
.
TENDER_SUB
DOMAIN
)};
var
require
=
{
baseUrl
:
window
.
baseUrl
};
</script>
<script
type=
"text/javascript"
src=
"${static.url("
js
/
vendor
/
require
.
js
")}"
></script>
...
...
cms/templates/widgets/tender.html
View file @
cfb1ec11
% if settings.TENDER_DOMAIN and user.is_authenticated():
% if settings.TENDER_
SUB
DOMAIN and user.is_authenticated():
<script
type=
"text/javascript"
>
window
.
Tender
=
{
hideToggle
:
true
,
...
...
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