Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
synnefo
Commits
4206b850
Commit
4206b850
authored
Mar 23, 2012
by
Kostas Papadimitriou
Browse files
Merge branch 'master' of
https://code.grnet.gr/git/synnefo
parents
c46ebf2d
b15b7a54
Changes
2
Hide whitespace changes
Inline
Side-by-side
snf-common/synnefo/lib/astakos.py
View file @
4206b850
...
...
@@ -83,7 +83,7 @@ def user_for_token(token, authentication_url, override_users):
except
:
return
None
def
get_user
(
request
,
authentication_url
=
'http://127.0.0.1:8000/im/authenticate'
,
override_users
=
{}):
def
get_user
(
request
,
authentication_url
=
'http://127.0.0.1:8000/im/authenticate'
,
override_users
=
{}
,
fallback_token
=
None
):
request
.
user
=
None
request
.
user_uniq
=
None
...
...
@@ -91,6 +91,8 @@ def get_user(request, authentication_url='http://127.0.0.1:8000/im/authenticate'
user
=
user_for_token
(
request
.
GET
.
get
(
'X-Auth-Token'
),
authentication_url
,
override_users
)
if
not
user
:
user
=
user_for_token
(
request
.
META
.
get
(
'HTTP_X_AUTH_TOKEN'
),
authentication_url
,
override_users
)
if
not
user
:
user
=
user_for_token
(
fallback_token
,
authentication_url
,
override_users
)
if
not
user
:
return
...
...
snf-cyclades-app/synnefo/tools/admin.py
View file @
4206b850
...
...
@@ -50,7 +50,7 @@ from optparse import OptionParser
from
os.path
import
basename
from
synnefo.db
import
models
from
synnefo.logic
import
backend
,
users
from
synnefo.logic
import
backend
from
synnefo.plankton.backend
import
ImageBackend
from
synnefo.util.dictconfig
import
dictConfig
...
...
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