-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Authentication with user/pass, OAuth2 and Keycloak #172
Conversation
497d856
to
764946c
Compare
80acff4
to
d86bf45
Compare
I've only tried out Gitlab auth so far but I noticed the following:
|
d86bf45
to
88808b4
Compare
- Add a login page - Add a login controller - Use JWT authentication - Make HttpClient service object that transparently auths requests - Add OAuth2 login to Ibutsu - Add tests for the login controller - Add Keycloak integration - Add authorisation, users can only see resources for projects they are part of - Use the 'from_file' method if it exists - Add support for running the dev servers under TLS
1eb5c71
to
fef5d8c
Compare
I've fixed up some DB queries that were wrong, maybe they were causing this issue? Everything works for me right now. |
@rsnyman Finally got a chance to check this out again today. Gitlab login is working fine but now I see when trying to access the runs page: File "/home/jdupuy/iqe/iqe-repos/ibutsu/ibutsu-server/backend/ibutsu_server/util/projects.py", line 40, in add_user_filter
query = query.filter(or_(project in user.projects, project.owner == user))
File "/home/jdupuy/iqe/iqe-repos/ibutsu/ibutsu-server/backend/.ibutsu-env/lib/python3.9/site-packages/sqlalchemy/orm/attributes.py", line 238, in __getattr__
util.raise_(
File "/home/jdupuy/iqe/iqe-repos/ibutsu/ibutsu-server/backend/.ibutsu-env/lib/python3.9/site-packages/sqlalchemy/util/compat.py", line 182, in raise_
raise exception
AttributeError: Neither 'InstrumentedAttribute' object nor 'Comparator' object associated with Run.project has an attribute 'owner' For the results page: File "/home/jdupuy/iqe/iqe-repos/ibutsu/ibutsu-server/backend/.ibutsu-env/lib/python3.9/site-packages/sqlalchemy/orm/attributes.py", line 238, in __getattr__
util.raise_(
File "/home/jdupuy/iqe/iqe-repos/ibutsu/ibutsu-server/backend/.ibutsu-env/lib/python3.9/site-packages/sqlalchemy/util/compat.py", line 182, in raise_
raise exception
AttributeError: Neither 'InstrumentedAttribute' object nor 'Comparator' object associated with Run.project has an attribute 'owner' Also, I'm wondering about the swagger UI, how can we authenticate there to mess with API queries? |
Superseded by #227 |
AuthService
for authenticationHttpClient
for all http calls