-
Notifications
You must be signed in to change notification settings - Fork 435
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from dharmin/master
Add ee4 configs
- Loading branch information
Showing
10 changed files
with
1,257 additions
and
31 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,36 +1,19 @@ | ||
server { | ||
server_name localhost; | ||
access_log /var/log/nginx/access.log; | ||
error_log /var/log/nginx/error.log; | ||
|
||
access_log /var/log/nginx/access.log; | ||
error_log /var/log/nginx/error.log; | ||
root /var/www/html; | ||
|
||
root /var/www/html; | ||
index index.php; | ||
server_name site1.test; | ||
|
||
if (!-e $request_filename) { | ||
rewrite /wp-admin$ $scheme://$host$uri/ permanent; | ||
rewrite ^(/[^/]+)?(/wp-.*) $2 last; | ||
rewrite ^(/[^/]+)?(/.*\.php) $2 last; | ||
} | ||
index index.php index.html index.htm; | ||
|
||
location / { | ||
try_files $uri $uri/ /index.php?$args; | ||
} | ||
|
||
location ~ \.php$ { | ||
try_files $uri =404; | ||
include fastcgi_params; | ||
fastcgi_pass php:9000; | ||
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; | ||
} | ||
# include common/redis-php7.conf; | ||
|
||
location = /robots.txt { | ||
return 200 'User-agent: * | ||
Disallow: /'; | ||
access_log off; | ||
log_not_found off; | ||
} | ||
include common/php7.conf; | ||
include common/wpcommon-php7.conf; | ||
include common/locations-php7.conf; | ||
|
||
client_max_body_size 100m; | ||
include /etc/nginx/sites-enabled/*; | ||
client_max_body_size 100m; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
DB_NAME=database_name | ||
DB_USER=database_user | ||
DB_PASSWORD=database_password | ||
|
||
# Optional variables | ||
DB_HOST=mysql | ||
# DB_PREFIX=wp_ | ||
|
||
WP_ENV=development | ||
WP_HOME=http://example.com | ||
WP_SITEURL=${WP_HOME} | ||
|
||
# Generate your keys here: https://roots.io/salts.html | ||
AUTH_KEY='generateme' | ||
SECURE_AUTH_KEY='generateme' | ||
LOGGED_IN_KEY='generateme' | ||
NONCE_KEY='generateme' | ||
AUTH_SALT='generateme' | ||
SECURE_AUTH_SALT='generateme' | ||
LOGGED_IN_SALT='generateme' | ||
NONCE_SALT='generateme' | ||
WP_CACHE_KEY_SALT='example.com:' #trailing `:` is important | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
MYSQL_ROOT_PASSWORD=password | ||
MYSQL_DATABASE=wordpress | ||
MYSQL_USER=wordpress | ||
MYSQL_PASSWORD=password | ||
|
||
WORDPRESS_DB_HOST=db | ||
VIRTUAL_HOST={V_HOST} | ||
VIRTUAL_HOST_EMAIL=[email protected] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
server { | ||
access_log /var/log/nginx/access.log; | ||
error_log /var/log/nginx/error.log; | ||
|
||
root /var/www/html; | ||
|
||
server_name site1.test; | ||
|
||
index index.php index.html index.htm; | ||
|
||
|
||
include common/redis-php7.conf; | ||
|
||
include common/wpcommon-php7.conf; | ||
include common/locations-php7.conf; | ||
|
||
client_max_body_size 100m; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Custom PHP settings | ||
|
||
upload_max_filesize = 100M | ||
post_max_size = 100M | ||
|
||
[mail function] | ||
sendmail_path = /usr/sbin/sendmail -S mail:1025 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
version: '3' | ||
|
||
services: | ||
mail: | ||
image: mailhog/mailhog | ||
restart: always | ||
command: ["-invite-jim=false"] | ||
labels: | ||
- traefik.enable=false | ||
environment: | ||
- VIRTUAL_HOST=mail.${VIRTUAL_HOST} | ||
- VIRTUAL_PORT=8025 | ||
networks: | ||
- site-network | ||
|
||
db: | ||
image: mysql:latest | ||
restart: always | ||
volumes: | ||
- "./app/db:/var/lib/mysql" | ||
labels: | ||
- traefik.enable=false | ||
environment: | ||
- MYSQL_ROOT_PASSWORD | ||
- MYSQL_DATABASE | ||
- MYSQL_USER | ||
- MYSQL_PASSWORD | ||
networks: | ||
- site-network | ||
|
||
php: | ||
image: rtcamp/wordpress | ||
depends_on: | ||
- db | ||
restart: always | ||
labels: | ||
- traefik.enable=false | ||
volumes: | ||
- "./app/src:/var/www/html" | ||
- "./config/php-fpm/php.ini:/usr/local/etc/php/php.ini" | ||
environment: | ||
- WORDPRESS_DB_HOST | ||
- WORDPRESS_DB_USER=${MYSQL_USER} | ||
- WORDPRESS_DB_PASSWORD=${MYSQL_PASSWORD} | ||
networks: | ||
- site-network | ||
|
||
nginx: | ||
image: dharmin/nginx:latest | ||
depends_on: | ||
- php | ||
restart: always | ||
environment: | ||
- VIRTUAL_HOST | ||
labels: | ||
- "traefik.backend=${VIRTUAL_HOST}" | ||
- "traefik.frontend.rule=HostRegexp:${VIRTUAL_HOST},{subdomain:[-a-z0-9]+}.${VIRTUAL_HOST}" | ||
volumes: | ||
- "./app/src:/var/www/html" | ||
- "./config/nginx/default.conf:/etc/nginx/conf.d/default.conf" | ||
- "./logs/nginx:/var/log/nginx" | ||
networks: | ||
- site-network | ||
|
||
networks: | ||
site-network: | ||
external: | ||
name: ${VIRTUAL_HOST} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
version: '3' | ||
|
||
services: | ||
mail: | ||
image: mailhog/mailhog | ||
restart: always | ||
command: ["-invite-jim=false"] | ||
environment: | ||
- VIRTUAL_HOST=mail.${VIRTUAL_HOST} | ||
- VIRTUAL_PORT=8025 | ||
networks: | ||
- site-network | ||
|
||
db: | ||
image: mysql:latest | ||
restart: always | ||
volumes: | ||
- "./app/db:/var/lib/mysql" | ||
environment: | ||
- MYSQL_ROOT_PASSWORD | ||
- MYSQL_DATABASE | ||
- MYSQL_USER | ||
- MYSQL_PASSWORD | ||
networks: | ||
- site-network | ||
|
||
phpmyadmin: | ||
image: phpmyadmin/phpmyadmin | ||
restart: always | ||
environment: | ||
- VIRTUAL_HOST=pma.${VIRTUAL_HOST} | ||
networks: | ||
- site-network | ||
|
||
php: | ||
image: wordpress/rtcamp | ||
depends_on: | ||
- db | ||
restart: always | ||
volumes: | ||
- "./app/src:/var/www/html" | ||
- "./config/php-fpm/php.ini:/usr/local/etc/php/php.ini" | ||
environment: | ||
- WORDPRESS_DB_HOST | ||
- WORDPRESS_DB_USER=${MYSQL_USER} | ||
- WORDPRESS_DB_PASSWORD=${MYSQL_PASSWORD} | ||
networks: | ||
- site-network | ||
|
||
nginx: | ||
image: dharmin/nginx:latest | ||
depends_on: | ||
- php | ||
restart: always | ||
environment: | ||
- VIRTUAL_HOST | ||
volumes: | ||
- "./app/src:/var/www/html" | ||
- "./config/nginx/default.conf:/etc/nginx/conf.d/default.conf" | ||
- "./logs/nginx:/var/log/nginx" | ||
networks: | ||
- site-network | ||
|
||
networks: | ||
site-network: | ||
external: | ||
name: ${VIRTUAL_HOST} |