-
Notifications
You must be signed in to change notification settings - Fork 6
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
ldap authentication with latest version #2
Comments
Hi Karl, The 'latest' branch is built from the code in the Transmart foundation's github repo. LDAP is an eTRIKS specific plugin and as far as i know it is not available in the foundation's version of Transmart. In a week or two we will have a brand new eTRIKS release. If possible for you i would suggest to wait until that release, as it will include all the latest developments from the Transmart Foundation's branch as well. I'll drop a comment in this thread once the new release is up. Thanks! |
Ok. I also think it's best to wait then. |
Ok, at the moment i'm not supporting any projects using it, nor am i using it myself. But if there are any issues we'll reach out to someone else within eTRIKS who has more knowledge on the LDAP plugin, and solve it together :) |
cool ! |
Hi Karl, eTRIKS v4 has been released and i have built the new docker images. The master branch now contains this release. Keep in mind that, when logging in, you have to click the "Federated login" link below the login form to be redirected to your custom login service. Denny |
Great, |
Hello, great work ! Did you solved the Rserve issue that was not starting ? If anyone has a successful procedure for setting the LDAP configuration right we are looking forward to it. Hector |
Hi Hector, Could you please provide the output of Thanks! |
same problem here:
no logs:
|
docker logs transmartdocker_tmrserve_1 won't give me any logs if it isn't started... A collegue of mine did it. He made a new Dockerfile i'll ask him if i can forward it to you. |
Interesting, i can confirm on an ubuntu 14.04 the same issue. I know Karl is running that, is that what you are running as well Hector? I see from the dockerfile you are getting the 16.1 version of transmart-data. It might be the case that having an older version will not install all required R packages (don't have time to check right now). This would impact things like SmartR and the advanced analysis workflows. In any case, building on a 14.04 system with the original Dockerfile also results in an image that runs on both 14.04 and 16.04, while the original image, built on a 16.04 system, does not run on 14.04. My best guess is that since there is a difference in kernel versions, there might be a difference in library versions being linked to when compiling R. The new image is now pushed to dockerhub. You should be able to pull it by just doing a |
Yes we are still on Ubuntu 14.04. I'll test your new version right away. And tell you the conclusion. Thanks. |
not better:
|
Same here. Still got the error. |
Strange, could you give me the output of |
|
building the local rserve container works for me (but it takes ages). |
Does not work, and the error messages look familiar:
|
Hi Karl, did you do a PS: when you want to upgrade the |
docker version Server: docker-compose version |
Thanks both for the replies, i have a system with the exact same versions of ubuntu, docker and compose as Karl but can not reproduce the rserve error. According to this post it's possible that my CPU where R was compiled, has instruction sets not available in your CPU. But i don't even know for sure which instruction sets are called by R. However it's starting to seem like one of the few remaining possibilities :p I could check if you gave me a Any luck with LDAP? In the meantime i've reached out within eTRIKS to see who is familiar with the LDAP configuration. |
I have done the docker-compose down -v. Same result: |
This exact same version (in fact the same war file) is running on an eTRIKS server, where we can log in with our central etriks credentials, through LDAP. So it should be available. I'll get back to you once i know more about the configuration. |
ok, so it might be my config. I'll check. |
Hi Karl, Just adding
I haven't heard back yet from my colleagues in etriks, but presumably you should use the configuration options listed on the Spring security LDAP grails plugin (version 2.0) manual here. I currently dont have an ldap server to test this against though. |
right, adding
solves the problem. Transmart launches, but I still can not connect using LDAP, but that's probably my config. |
Yes, sorry about that! I was confusing the SAML login with LDAP login. LDAP uses the regular login form and connects to the ldap server behind the scenes. SAML is if you have a single sign on service with which you want to integrate. Therefore it needs this extra link to redirect you to the single sign on server. |
Trying to debug the LDAP: when trying to connect, I get this in transmart.log:
additionally, and probably not related, there are numerous errors about Rserve:
|
Regarding rserve, the transmart error says it cannot connect to rserve. If the rserve container is running, and is on the
To directly test if the rserve container is available from the tmapp container:
|
Yes it pings. And the /transmart-data/R/root/lib/R/bin/Rserve.dbg process is running in tmrserve. |
solved the rserve problem, was due to my Config.groovy, sorry. |
Great you found it! 😄 no problem. In the meantime i've had some responses regarding LDAP. In attached file tm_struct.ldif you can find the groups necessary for transmart to be in ldap. cnorris.ldif an example transmart user in LDAP, and in tmconfig.txt the relevant config section to put in Config.groovy. |
I tried to mix my config with your concerning authentication/authorization, but it still fails. The crux seems to be: My ldap config seems to work:
|
my config seems quite close to tmconfig.txt, I disabled oauth and saml:
|
"rserve Config.groovy problem", what kind of problem exactly ? |
@hcountou: my host was localhost, based on my existing config, which does not use linked (or networked) containers. |
Ok so we're getting closer! The default transmart installation comes with a number of preconfigured users, admin, guest, and a few more. It seems it wants to insert the ldap user into there as well, but for some reason takes an existing id. I'm not sure if this is expected behavior. I'll reach out to another developer in etriks. |
ok, makes sense. Because I configured it to only use ldap provider, it must not load users already in DB... |
Hi Karl, So, in the case of LDAP authentication, transmart still stores the credentials in its own database, since it relies on this for permissions grouping and so on. TM will keep authenticating against LDAP, but will always update its local profile of the user. In the meantime i've set up an openldap locally to test this out, and also encountered the same issue you encountered. TM comes with a few accounts pre-configured (admin, guest, etc). The reason for our issue is that the mapping logic does not correctly take into account users already stored in the database, and as a result tries to store the LDAP user with a primary key that's already in use. This is a bug and we will resolve it in a future release. However, since you are only using LDAP for authentication, and no local accounts, we can safely remove the preconfigured users from the database using:
When you try to login now, it should be successful. See an excerpt from the logs on my local instance logging in after clearing out the local transmart users:
After this, additional ldap logins get added without a problem to the local database as well, so you should be good to go! Hope this helps 😄 Denny |
Brilliant ! Works perfectly !!!
The transmart app is to be under the umbrella of an apache reverse-proxy of mine. Should I disable tmweb ? |
Great!! For the database: i can point you to this volume driver. I've used it before. When you've installed it, it allows you to create a named volume that is mounted on a specified location in your host system, like this:
The DB port is exported by the default compose file, but only to localhost, for security reasons. If you want to expose it to remote hosts as well, just remove the Finally, yes you can safely disable the Good luck! |
Hi,
So on one of my server I can run tmapp. It works with the default Config.groovy. If I try to put the LDAP related bits from my current working config with the old instance, it does not seem to be taken into account (i.e. I can not login with the LDAP credentials).
If I just replace the Config.groovy with the old one, tmapp crashes. I can see these types of messages in the logs:
So my question: do you have any information about how to setup LDAP authentication with this version, and if some thing has changed regarding the configuration ?
Thanks.
Karl
The text was updated successfully, but these errors were encountered: