From c1c07ef619db13ed98ab7d399706130103671514 Mon Sep 17 00:00:00 2001 From: cupcakearmy Date: Sun, 25 Aug 2019 18:40:19 +0200 Subject: [PATCH] docker files --- config/.env | 8 ++++++++ config/Dockerfile | 11 +++++++++++ config/uploads.ini | 5 +++++ docker-compose.yml | 23 +++++++++++++++++++++++ 4 files changed, 47 insertions(+) create mode 100644 config/.env create mode 100644 config/Dockerfile create mode 100644 config/uploads.ini create mode 100755 docker-compose.yml diff --git a/config/.env b/config/.env new file mode 100644 index 0000000..21e147b --- /dev/null +++ b/config/.env @@ -0,0 +1,8 @@ +WORDPRESS_DB_HOST=db +WORDPRESS_DB_USER=root +WORDPRESS_DB_PASSWORD=example +WORDPRESS_DB_NAME=wordpress +WORDPRESS_TABLE_PREFIX= + +MYSQL_ROOT_PASSWORD=example +MYSQL_DATABASE=wordpress \ No newline at end of file diff --git a/config/Dockerfile b/config/Dockerfile new file mode 100644 index 0000000..f66ed0e --- /dev/null +++ b/config/Dockerfile @@ -0,0 +1,11 @@ +FROM wordpress:5-php7.3-apache + +# # Possible +# # bcmath bz2 calendar ctype curl dba dom enchant exif fileinfo filter ftp gd gettext gmp hash +# # iconv imap interbase intl json ldap mbstring mysqli oci8 odbc opcache pcntl pdo pdo_dblib +# # pdo_firebird pdo_mysql pdo_oci pdo_odbc pdo_pgsql pdo_sqlite pgsql phar posix pspell readline +# # recode reflection session shmop simplexml snmp soap sockets sodium spl standard sysvmsg sysvsem +# # sysvshm tidy tokenizer wddx xml xmlreader xmlrpc xmlwriter xsl zend_test zip + +RUN docker-php-ext-install pdo_mysql \ + && a2enmod ext_filter headers \ No newline at end of file diff --git a/config/uploads.ini b/config/uploads.ini new file mode 100644 index 0000000..01fb05c --- /dev/null +++ b/config/uploads.ini @@ -0,0 +1,5 @@ +file_uploads = On +memory_limit = 512M +upload_max_filesize = 512M +post_max_size = 512M +max_execution_time = 300 \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100755 index 0000000..19e6920 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,23 @@ +version: '3.7' + +x-default: &default + restart: unless-stopped + env_file: ./config/.env + +services: + + wp: + <<: *default + build: ./config + ports: + - 80:80 + volumes: + - ./config/uploads.ini:/usr/local/etc/php/conf.d/uploads.ini:ro + - ./data/wp:/var/www/html + - ./theme:/var/www/html/wp-content/themes/theme:ro + + db: + <<: *default + image: mariadb:10.3 + volumes: + - ./data/db:/var/lib/mysql \ No newline at end of file