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
OpenEdx
configuration
Commits
9a75c7fa
Commit
9a75c7fa
authored
Jun 24, 2014
by
John Jarvis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add nginx for analytics-api
parent
25ccffd0
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
40 additions
and
1 deletions
+40
-1
playbooks/edx-east/analyticsapi.yml
+3
-0
playbooks/edx-east/edx_continuous_integration.yml
+1
-0
playbooks/roles/analytics-api/defaults/main.yml
+2
-1
playbooks/roles/nginx/defaults/main.yml
+2
-0
playbooks/roles/nginx/templates/edx/app/nginx/sites-available/analytics-api.j2
+32
-0
No files found.
playbooks/edx-east/analyticsapi.yml
View file @
9a75c7fa
...
...
@@ -7,6 +7,9 @@
ENABLE_SPLUNKFORWARDER
:
False
ENABLE_NEWRELIC
:
False
roles
:
-
role
:
nginx
nginx_sites
:
-
analytics-api
-
aws
-
analytics-api
-
role
:
datadog
...
...
playbooks/edx-east/edx_continuous_integration.yml
View file @
9a75c7fa
...
...
@@ -16,6 +16,7 @@
-
xqueue
-
xserver
-
certs
-
analytics-api
nginx_default_sites
:
-
lms
-
edxlocal
...
...
playbooks/roles/analytics-api/defaults/main.yml
View file @
9a75c7fa
...
...
@@ -17,6 +17,7 @@ ANALYTICS_API_GIT_IDENTITY: !!null
# and a key being provided via NEWRELIC_LICENSE_KEY
ANALYTICS_API_NEWRELIC_APPNAME
:
"
your
Newrelic
appname"
ANALYTICS_API_PIP_EXTRA_ARGS
:
"
-i
{{
COMMON_PYPI_MIRROR_URL
}}"
ANALYTICS_API_NGINX_PORT
:
"
18080"
#
# vars are namespace with the module name.
...
...
@@ -32,7 +33,7 @@ analytics_api_venv_dir: "{{ analytics_api_venv_base }}/{{ analytics_api_service_
analytics_api_venv_bin
:
"
{{
analytics_api_venv_dir
}}/bin"
analytics_api_code_dir
:
"
{{
analytics_api_app_dir
}}/edx-analytics-data-api"
analytics_api_conf_dir
:
"
{{
analytics_api_home
}}"
analytics_api_gunicorn_host
:
"
0.0.0.0
"
analytics_api_gunicorn_host
:
"
127.0.0.1
"
analytics_api_gunicorn_port
:
"
8080"
analytics_api_gunicorn_workers
:
"
8"
analytics_api_gunicorn_timeout
:
"
300"
...
...
playbooks/roles/nginx/defaults/main.yml
View file @
9a75c7fa
...
...
@@ -51,6 +51,8 @@ nginx_lms_preview_gunicorn_hosts:
-
127.0.0.1
nginx_cms_gunicorn_hosts
:
-
127.0.0.1
nginx_analytics_api_gunicorn_hosts
:
-
127.0.0.1
nginx_cfg
:
# - link - turn on
...
...
playbooks/roles/nginx/templates/edx/app/nginx/sites-available/analytics-api.j2
0 → 100644
View file @
9a75c7fa
upstream analytics_api_app_server {
{% for host in nginx_analytics_api_gunicorn_hosts %}
server {{ host }}:{{ analytics_api_gunicorn_port }} fail_timeout=0;
{% endfor %}
}
server {
listen {{ ANALYTICS_API_NGINX_PORT }} default_server;
location / {
{% include "basic-auth.j2" %}
try_files $uri @proxy_to_app;
}
# No basic auth security on the heartbeat url, so that ELB can use it
location /analytics_api/status/{
try_files $uri @proxy_to_app;
}
{% include "robots.j2" %}
location @proxy_to_app {
proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto;
proxy_set_header X-Forwarded-Port $http_x_forwarded_port;
proxy_set_header X-Forwarded-For $http_x_forwarded_for;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_pass http://analytics_api_app_server;
}
}
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