added nginx reverse proxi conf

This commit is contained in:
2019-03-11 14:07:11 +01:00
parent 3544b5aff9
commit 566cc4886b
+36 -3
View File
@@ -33,7 +33,9 @@ add to your /etc/hosts :
127.0.0.1 dev.encyclopediedelaparole.org 127.0.0.1 dev.encyclopediedelaparole.org
127.0.0.1 dev.phpmyadmin.encyclopediedelaparole.org 127.0.0.1 dev.phpmyadmin.encyclopediedelaparole.org
``` ```
configure your apache vhosts to add a reverse proxy that will redirect the dev.encyclopediedelaparole.org to our container configure your apache or nginx vhosts to add a reverse proxy that will redirect the dev.encyclopediedelaparole.org to our container
apache
``` ```
<Virtualhost *:80> <Virtualhost *:80>
ServerName dev.encyclopediedelaparole.org ServerName dev.encyclopediedelaparole.org
@@ -50,6 +52,37 @@ configure your apache vhosts to add a reverse proxy that will redirect the dev.e
ProxyRequests Off ProxyRequests Off
</Virtualhost> </Virtualhost>
``` ```
nginx
```
server {
listen 80;
server_name dev.encyclopediedelaparole.org;
location / {
proxy_pass http://127.0.0.1:8880;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
server {
listen 80;
server_name dev.phpmyadmin.encyclopediedelaparole.org;
location / {
proxy_pass http://127.0.0.1:8881;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
```
## Docker ## Docker
### build ### build
@@ -83,9 +116,9 @@ sudo docker exec -it edlpd8_php_1 bash
once inside the php container in /var/www/html you can use drush as usual once inside the php container in /var/www/html you can use drush as usual
### gulp ### gulp
Dev process needs gulp to run in: Dev process needs gulp to run in:
- public_html/sites/all/modules/figli/edlp_corpus/ - public_html/sites/all/modules/figli/edlp_corpus/
- public_html/sites/all/themes/custom/edlptheme/ - public_html/sites/all/themes/custom/edlptheme/
if you have to modifie js or scss source code, you need to do in each of these 2 folder: if you have to modifie js or scss source code, you need to do in each of these 2 folder:
``` ```
npm install npm install