phpearth / docker-php

🐳 Docker For PHP developers - Docker images with PHP, Nginx, OpenLiteSpeed, Apache, Lighttpd, and Alpine
https://docs.php.earth/docker
MIT License
261 stars 80 forks source link

How to enable apache rewrite ? #39

Open mysignisleo opened 4 years ago

mysignisleo commented 4 years ago

I have the .htaccess under the app folder . But it's not working. And i want to enter the container , but not working too. docker exec -it container bash

samundra commented 4 years ago

@jerryjee you can create your own Dockerfile and then copy your .htaccess using command ADD or COPY

Here is https://github.com/samundra/tus-php/blob/feature/update-docker-setup/docker/server/Dockerfile#L6 which I am borrowing from one of project I am working on.

You have to figure out where you have to copy .htaccess file. Usually, it's placed on Apache Document Root.