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
Please enable mod_rewrite #377
Comments
I haven't use mod_rewrite since While most projects still describe how to get set up with mod_rewrite, I have yet to find one where replacing mod_rewrite with FallbackResource does not work. It looks like most developers have just been using mod_rewrite to fallback to a php script and not for any serious rewriting. |
Just in case you need mod rewrite, create a simple Dockerfile with this content
|
i know how to do that |
We don't support any non-default mods being on by default. We'd rather not turn on extra mods that might not be used. We swap $ docker run -d --name apache-rewrite php:7-apache sh -c 'a2enmod rewrite && exec docker-php-entrypoint apache2-foreground'
$ docker exec -it apache-rewrite bash
root@5f9d9d912c6a:/var/www/html# ls /etc/apache2/mods-enabled/ | grep rewrite
rewrite.load |
As these kind of questions pop up again and again, it may make sense to add a FAQ section to the README with links to articles that describe "how do it the right way" approaches (kind of "before vs. after"). Alternatively, they could simply link directly to appropriate answers in GitHub issues like this one. |
Like this? https://github.com/docker-library/docs/tree/master/php#how-to-install-more-php-extensions 😞 edit: that one only covers php exts, this is about apache |
I'm really trying to address common questions that pop up again and again, hence literally a FAQ section. |
after deliberating for a while, i think it is true to only leave default stuffs on and any additional stuffs should be bundled with a custom image So i agree with that logic |
@babatundebusari As you write yourself, mod_rewrite is very popular and widespread use is common (Wordpress, Joomla!, et al.). Therefore, it's likely that this very question will pop up again. I think it would make sense to address this problem to avoid the question being asked again and again. |
lets add this to the README ? :) |
Why not just provide environment variable, read modules and enable them in entrypoint script? |
mod_rewrite is like a very popular module and mostly needed with apache
most people will be using nginx anyways if not mostly because of mod_rewrite with apache
will be GREAT to OFFICIALLY enable mod_rewrite by default to the official image
Yes we can create own own custom image but would be BETTER if its added to official by default
Thanks
The text was updated successfully, but these errors were encountered: