passenger icon indicating copy to clipboard operation
passenger copied to clipboard

Support for mod_userdir

Open FooBarWidget opened this issue 11 years ago • 13 comments

From benabik on April 22, 2008 18:46:57

Using passenger on the root of a web server prevents userdir requests (such as ~user) from being handled properly. Ideally, Passenger should allow mod_userdir to handle requests before attempting to send them to the rails application.

Original issue: http://code.google.com/p/phusion-passenger/issues/detail?id=33

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From honglilai on April 22, 2008 10:09:26

Status: Accepted
Labels: -Type-Defect Type-Enhancement

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From honglilai on April 22, 2008 10:10:51

Summary: mod_userdir is incompatible (Passenger ignores mod_userdir)
Labels: ConflictingModule

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From benabik on June 17, 2008 11:13:39

Is this issue solved in Passenger 2.0-rc1? This is blocking my deployment of passenger.

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From honglilai on June 17, 2008 11:17:20

No support for it at the moment.

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From benabik on February 04, 2009 00:20:06

I've written a basic patch that seems to allow mod_userdir to handle requests intended for it by simply ignoring things that look like userdir requests when the Passenger app is running from / and mod_userdir is loaded.

This at least seems like the right place to start. I couldn't find a way to tell if mod_userdir was enabled, only if it was loaded. Nor does it attempt to validate the userdir call at all, so requests like /~invalid_user get the standard Apache 404 page instead of the application 404.

I also did not test if Passenger applications inside a userdir worked. However, I don't believe they worked previously so this at least isn't a regression.

Attachment: 0001-Ignore-requests-for-mod_userdir.patch

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From honglilai on February 04, 2009 00:42:21

Labels: -Type-Enhancement Type-Patch

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From jphpsf on September 15, 2010 08:57:59

Resolving this would be really useful.

For now, I am deploying multiple apps under DocumentRoot of Apache. I will probably try the mass deployment feature from passenger 3 soon and have it point to ~/public_html

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

From xdiscent2 on November 19, 2010 09:11:32

how is this? implemented already?

FooBarWidget avatar May 29 '14 07:05 FooBarWidget

Listed as not compatible for now.

OnixGH avatar Feb 05 '16 14:02 OnixGH

Is this still not a thing?

RafaelDeJongh avatar Jun 05 '19 08:06 RafaelDeJongh

No this hasn't seen any progress. But we're open to PRs.

CamJN avatar Jun 05 '19 15:06 CamJN

Damn, I'm totally not familiar with such code but totally would love to help out but would not know where to start to be honest! It's just really sad now that cPanel released their own native NodeJS apptm that relies on this module but many webhost also use the other mod that I mentioned, especially shared... I was really really looking forward for this and it's quite the letdown not only for this not being compatible but also from my host not even trying to find a different solution other than saying they're not compatible.

Could I ask where it exactly does conflict maybe I could look into it and learn while I look into it!

RafaelDeJongh avatar Jun 07 '19 04:06 RafaelDeJongh

This at least seems like the right place to start. I couldn't find a way to tell if mod_userdir was enabled, only if it was loaded. Nor does it attempt to validate the userdir call at all, so requests like /~invalid_user get the standard Apache 404 page instead of the application 404.

Updating the patch to apply cleanly to the current codebase as well as answering the questions @FooBarWidget still had last he looked at this would be the next steps here.

CamJN avatar Jun 19 '19 15:06 CamJN