Gitlab CSE Unil
Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
M. Chardon
ADIM
Commits
6a087d5b
Commit
6a087d5b
authored
Jun 08, 2015
by
Julien Furrer
Browse files
Fixed trailing slash at the end of BASE_URL
parent
0f30e1d3
Changes
6
Hide whitespace changes
Inline
Side-by-side
adim_project/adim_project/apache/production.conf
View file @
6a087d5b
...
...
@@ -67,7 +67,7 @@
WSGIDaemonProcess
adim
.
django
user
=
www
-
data
group
=
www
-
data
WSGIScriptAlias
/
adim
/
"/var/django/projects/adim.django/adim_project/adim_project/wsgi/production.py"
WSGIScriptAlias
/
adim
"/var/django/projects/adim.django/adim_project/adim_project/wsgi/production.py"
<
Directory
"/var/django/projects/adim.django/adim_project/adim_project"
>
WSGIProcessGroup
adim
.
django
WSGIPassAuthorization
On
...
...
adim_project/adim_project/apache/staging.conf
View file @
6a087d5b
...
...
@@ -67,7 +67,7 @@
WSGIDaemonProcess
adim
-
dev
.
django
user
=
www
-
data
group
=
www
-
data
WSGIScriptAlias
/
adim
-
dev
/
"/var/django/projects/adim-dev.django/adim_project/adim_project/wsgi/staging.py"
WSGIScriptAlias
/
adim
-
dev
"/var/django/projects/adim-dev.django/adim_project/adim_project/wsgi/staging.py"
<
Directory
"/var/django/projects/adim-dev.django/adim_project/adim_project"
>
WSGIProcessGroup
adim
-
dev
.
django
WSGIPassAuthorization
On
...
...
adim_project/adim_project/settings/base.py
View file @
6a087d5b
...
...
@@ -119,8 +119,8 @@ def update_urls(base_url=None, name=__name__):
setattr
(
this_module
,
'BASE_URL'
,
base_url
)
setattr
(
this_module
,
'SESSION_COOKIE_PATH'
,
base_url
)
setattr
(
this_module
,
'CSRF_COOKIE_PATH'
,
base_url
)
setattr
(
this_module
,
'MEDIA_URL'
,
'{}media/'
.
format
(
base_url
))
setattr
(
this_module
,
'STATIC_URL'
,
'{}static/'
.
format
(
base_url
))
setattr
(
this_module
,
'MEDIA_URL'
,
'{}
/
media/'
.
format
(
base_url
))
setattr
(
this_module
,
'STATIC_URL'
,
'{}
/
static/'
.
format
(
base_url
))
update_urls
(
"/"
)
# ---------- END URL CONFIGURATION
...
...
adim_project/adim_project/settings/production.py
View file @
6a087d5b
...
...
@@ -4,7 +4,7 @@ Settings for production server
from
.base
import
*
update_urls
(
'/adim
/
'
,
__name__
)
update_urls
(
'/adim'
,
__name__
)
ALLOWED_HOSTS
=
[
'.unil.ch'
]
...
...
adim_project/adim_project/settings/staging.py
View file @
6a087d5b
...
...
@@ -6,7 +6,7 @@ from .base import *
DEBUG
=
True
TEMPLATE_DEBUG
=
TEMPLATES
[
0
][
'OPTIONS'
][
'debug'
]
=
True
update_urls
(
'/adim-dev
/
'
,
__name__
)
update_urls
(
'/adim-dev'
,
__name__
)
ALLOWED_HOSTS
=
[
'.unil.ch'
]
...
...
adim_project/templates/apache_config/base.conf
View file @
6a087d5b
...
...
@@ -62,7 +62,7 @@
# Shibboleth Conf
# ---------------
<
IfModule
mod_shib
>
<
Location
{{
settings
.
BASE_URL
}}
shibauth
/>
<
Location
{{
settings
.
BASE_URL
}}
/
shibauth
/>
#Order allow,deny
#Allow from all
AuthType
shibboleth
...
...
@@ -93,7 +93,7 @@
</
Files
>
</
Directory
>
{%
if
settings
.
BASE_URL
and
settings
.
BASE_URL
!=
"/"
%}
RedirectMatch
^{{
settings
.
BASE_URL
|
slice
:
"-1"
}}$ {{
settings
.
BASE_URL
}}
RedirectMatch
^{{
settings
.
BASE_URL
}}$ {{
settings
.
BASE_URL
}}
{%
endif
%}
{%
endblock
wsgi
%}
...
...
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