Skip to content
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

Make this work behind https frontend proxy #122

Open
wants to merge 4 commits into
base: next_release
Choose a base branch
from

Conversation

giggls
Copy link

@giggls giggls commented Sep 30, 2021

Hello,

these changes might close #109. These 3 commits are how we got this to work behind an nginx frontend proxy and have apache listening on a selectable port (not hardcoded to 80).

However, we did not test if it still works without the frontend proxy.

Regards

Sven

@giggls giggls changed the title Make this work behinf https frontend proxy Make this work behind https frontend proxy Sep 30, 2021
@wheelybird
Copy link
Owner

Hi. The port Apache listens on shouldn't need to change as it's up to Docker to map the host port to the container port.
Some of the changes you made would generate invalid URLs as the root path would be duplicated.
With regards to the cookies, did you try using this container: wheelybird/ldap-user-manager:oldcookies?
I still haven't been able to reproduce the cookie issues on any browsers I use, even when using Nginx as a reverse proxy. I suspect the issue lies in the Nginx configuration or version that people are using.

@giggls
Copy link
Author

giggls commented Sep 30, 2021

The reason I need to map the port away from 80 is because I need to run docker in network=host mode in my use-case.

Your oldcookies container does work as far as the login is concerned but the SERVER_PATH stuff needed further patching.

To reflect these 3 things we made 3 commits.

As I already wrote this is untested with the default SERVER_PATH=/ setting.

Regards

Sven

@wheelybird wheelybird changed the base branch from master to next_release March 9, 2022 15:59
@mstup
Copy link

mstup commented Dec 17, 2023

Hey @wheelybird
Looks like I been faced with the some similar issue on work from behind of proxy.
I have couple issues which blocked me with final decision about wheelybird/ldap-user-manager:v1.11

For LogIn

  1. I have Nginx proxy configured to open wheelybird on path myhost/ldap. No problem with this, initial page in opens and I can enter username and password.
    image

  2. But after click on LogIn button the next page is lost prefix "/ldap" and tried to open root path.
    image

Here how LogIn traffic looks like:
image

For Groups

The same path prefix lost is on attempt to save new Group.

Group management page opens fine.
image

But on final step when click on Save button, the prefix /ldap is lost
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't start setup or login behind nginx v1.7 (v1.6 works, but without subfolder)
3 participants