Commit 1d92158ca876a2805a4f46ab5f7984e941a271c3
1 parent
2be27bf9
Exists in
master
and in
39 other branches
Moved gitlab, jenkins and redmine to django apps
Showing
22 changed files
with
83 additions
and
55 deletions
Show diff stats
src/proxy/admin.py
src/proxy/tests.py
src/proxy/urls.py
... | ... | @@ -1,16 +0,0 @@ |
1 | - | |
2 | -from django.conf.urls import patterns, include, url | |
3 | - | |
4 | -from .views import JenkinsProxyView, GitlabProxyView, RedmineProxyView | |
5 | - | |
6 | - | |
7 | -urlpatterns = patterns('', | |
8 | - # Jenkins URLs | |
9 | - url(r'^ci/(?P<path>.*)$', JenkinsProxyView.as_view()), | |
10 | - | |
11 | - # Gitlab | |
12 | - url(r'^gitlab/(?P<path>.*)$', GitlabProxyView.as_view()), | |
13 | - | |
14 | - # Redmine | |
15 | - url(r'^redmine/(?P<path>.*)$', RedmineProxyView.as_view()) | |
16 | -) |
src/proxy/views.py
... | ... | @@ -1,33 +0,0 @@ |
1 | - | |
2 | -import os | |
3 | - | |
4 | -from django.conf import settings | |
5 | - | |
6 | -from revproxy.views import ProxyView | |
7 | - | |
8 | - | |
9 | -CWD = os.path.abspath(os.path.dirname(__file__)) | |
10 | -DIAZO_RULES_DIR = os.path.join(CWD, 'diazo') | |
11 | - | |
12 | - | |
13 | -class JenkinsProxyView(ProxyView): | |
14 | - base_url = settings.COLAB_CI_URL | |
15 | - add_remote_user = settings.REVPROXY_ADD_REMOTE_USER | |
16 | - diazo_theme_template = 'base.html' | |
17 | - diazo_rules = os.path.join(DIAZO_RULES_DIR, 'jenkins.xml') | |
18 | - html5 = True | |
19 | - | |
20 | -class GitlabProxyView(ProxyView): | |
21 | - base_url = settings.COLAB_GITLAB_URL | |
22 | - add_remote_user = settings.REVPROXY_ADD_REMOTE_USER | |
23 | - diazo_theme_template = 'proxy/gitlab.html' | |
24 | - diazo_rules = os.path.join(DIAZO_RULES_DIR, 'gitlab.xml') | |
25 | - html5 = True | |
26 | - | |
27 | -class RedmineProxyView(ProxyView): | |
28 | - base_url = settings.COLAB_REDMINE_URL | |
29 | - add_remote_user = settings.REVPROXY_ADD_REMOTE_USER | |
30 | - diazo_theme_template = 'proxy/redmine.html' | |
31 | - diazo_rules = os.path.join(DIAZO_RULES_DIR, 'redmine.xml') | |
32 | - html5 = True | |
33 | - |