first commit

This commit is contained in:
2020-05-18 14:41:25 +02:00
commit 309a5e5129
16 changed files with 335463 additions and 0 deletions
+10
View File
@@ -0,0 +1,10 @@
TZ=Europe/Paris
PHP_VERSION=php:7.3-fpm
MYSQL_VERSION=mariadb
MYSQL_ROOT_PASSWORD=root
PMA_VERSION=phpmyadmin/phpmyadmin
NGINX_VERSION=nginx
+39
View File
@@ -0,0 +1,39 @@
FROM php:7.3-fpm
RUN apt-get update && apt-get install -y \
libfreetype6-dev \
libjpeg62-turbo-dev \
libmcrypt-dev \
libpng-dev \
mariadb-client \
zip \
libzip-dev && \
# docker-php-ext-install -j$(nproc) iconv && \
docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ && \
apt-get install -y imagemagick libmagickwand-dev && \
#pecl install imagick && docker-php-ext-enable imagick && \
docker-php-ext-install -j$(nproc) gd && \
docker-php-ext-install pdo_mysql mysqli zip && \
docker-php-ext-install opcache && \
docker-php-ext-install bcmath && \
apt-get install -y git vim && \
# pecl install redis-4.3.0 && \
# pecl install xdebug-2.7.0 && \
docker-php-ext-enable redis xdebug mysqli
RUN export COMPOSER_HOME=/usr/local/composer && \
curl -sS https://getcomposer.org/installer \
| php -- --install-dir=/usr/local/bin --filename=composer && \
curl https://drupalconsole.com/installer \
-L -o /usr/local/bin/drupal && \
chmod +x /usr/local/bin/drupal && \
curl https://github.com/drush-ops/drush-launcher/releases/download/0.6.0/drush.phar \
-L -o /usr/local/bin/drush && \
chmod +x /usr/local/bin/drush
RUN apt-get install -y curl && \
curl -sL https://deb.nodesource.com/setup_11.x | bash - && \
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list && \
apt-get update && \
apt-get install -y nodejs yarn
+150
View File
@@ -0,0 +1,150 @@
;;;;;;;;;;;;;;;;;;;;;
; FPM Configuration ;
;;;;;;;;;;;;;;;;;;;;;
; All relative paths in this configuration file are relative to PHP's install
; prefix (/usr/local). This prefix can be dynamically changed by using the
; '-p' argument from the command line.
;;;;;;;;;;;;;;;;;;
; Global Options ;
;;;;;;;;;;;;;;;;;;
[global]
; Pid file
; Note: the default prefix is /usr/local/var
; Default Value: none
;pid = run/php-fpm.pid
; Error log file
; If it's set to "syslog", log is sent to syslogd instead of being written
; into a local file.
; Note: the default prefix is /usr/local/var
; Default Value: log/php-fpm.log
;error_log = log/php-fpm.log
; syslog_facility is used to specify what type of program is logging the
; message. This lets syslogd specify that messages from different facilities
; will be handled differently.
; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON)
; Default Value: daemon
;syslog.facility = daemon
; syslog_ident is prepended to every message. If you have multiple FPM
; instances running on the same server, you can change the default value
; which must suit common needs.
; Default Value: php-fpm
;syslog.ident = php-fpm
; Log level
; Possible Values: alert, error, warning, notice, debug
; Default Value: notice
;log_level = notice
; Log limit on number of characters in the single line (log entry). If the
; line is over the limit, it is wrapped on multiple lines. The limit is for
; all logged characters including message prefix and suffix if present. However
; the new line character does not count into it as it is present only when
; logging to a file descriptor. It means the new line character is not present
; when logging to syslog.
; Default Value: 1024
;log_limit = 4096
; Log buffering specifies if the log line is buffered which means that the
; line is written in a single write operation. If the value is false, then the
; data is written directly into the file descriptor. It is an experimental
; option that can potentionaly improve logging performance and memory usage
; for some heavy logging scenarios. This option is ignored if logging to syslog
; as it has to be always buffered.
; Default value: yes
;log_buffering = no
; If this number of child processes exit with SIGSEGV or SIGBUS within the time
; interval set by emergency_restart_interval then FPM will restart. A value
; of '0' means 'Off'.
; Default Value: 0
;emergency_restart_threshold = 0
; Interval of time used by emergency_restart_interval to determine when
; a graceful restart will be initiated. This can be useful to work around
; accidental corruptions in an accelerator's shared memory.
; Available Units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
;emergency_restart_interval = 0
; Time limit for child processes to wait for a reaction on signals from master.
; Available units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
;process_control_timeout = 0
; The maximum number of processes FPM will fork. This has been designed to control
; the global number of processes when using dynamic PM within a lot of pools.
; Use it with caution.
; Note: A value of 0 indicates no limit
; Default Value: 0
; process.max = 128
; Specify the nice(2) priority to apply to the master process (only if set)
; The value can vary from -19 (highest priority) to 20 (lowest priority)
; Note: - It will only work if the FPM master process is launched as root
; - The pool process will inherit the master process priority
; unless specified otherwise
; Default Value: no set
; process.priority = -19
; Send FPM to background. Set to 'no' to keep FPM in foreground for debugging.
; Default Value: yes
;daemonize = yes
; Set open file descriptor rlimit for the master process.
; Default Value: system defined value
;rlimit_files = 1024
; Set max core size rlimit for the master process.
; Possible Values: 'unlimited' or an integer greater or equal to 0
; Default Value: system defined value
;rlimit_core = 0
; Specify the event mechanism FPM will use. The following is available:
; - select (any POSIX os)
; - poll (any POSIX os)
; - epoll (linux >= 2.5.44)
; - kqueue (FreeBSD >= 4.1, OpenBSD >= 2.9, NetBSD >= 2.0)
; - /dev/poll (Solaris >= 7)
; - port (Solaris >= 10)
; Default Value: not set (auto detection)
;events.mechanism = epoll
; When FPM is built with systemd integration, specify the interval,
; in seconds, between health report notification to systemd.
; Set to 0 to disable.
; Available Units: s(econds), m(inutes), h(ours)
; Default Unit: seconds
; Default value: 10
;systemd_interval = 10
;;;;;;;;;;;;;;;;;;;;
; Pool Definitions ;
;;;;;;;;;;;;;;;;;;;;
; Multiple pools of child processes may be started with different listening
; ports and different management options. The name of the pool will be
; used in logs and stats. There is no limitation on the number of pools which
; FPM can handle. Your system will tell you anyway :)
; Include one or more files. If glob(3) exists, it is used to include a bunch of
; files from a glob(3) pattern. This directive can be used everywhere in the
; file.
; Relative path can also be used. They will be prefixed by:
; - the global prefix if it's been set (-p argument)
; - /usr/local otherwise
include=etc/php-fpm.d/*.conf
max_execution_time = 600
max_input_time = 600
memory_limit = 2500M
post_max_size = 0
upload_max_filesize = 256M
View File
+2
View File
@@ -0,0 +1,2 @@
{
}
+2
View File
@@ -0,0 +1,2 @@
*
!.gitignore
+67
View File
@@ -0,0 +1,67 @@
version: '3.2'
services:
nginx:
container_name: nginx_lamine
image: "${NGINX_VERSION}"
ports:
- 80:80
- 443:443
volumes:
- ./log/nginx:/var/log/nginx
- ./etc/nginx/nginx.conf:/etc/nginx/nginx.conf
- ./etc/nginx/conf.d:/etc/nginx/conf.d
- ./etc/nginx/ssl:/etc/nginx/ssl
- ./wwwroot:/var/www
environment:
ENABLE_CRONTAB: "true"
TZ: ${TZ}
restart: on-failure
php-fpm:
container_name: php_lamine
# image: "${PHP_VERSION}"
build: ./Docker/php-fpm/
volumes:
- ./etc/php-fpm/php-fpm.ini:/usr/local/etc/php-fpm.ini
# - ./etc/php-fpm/crontabs:/etc/crontabs
- ./wwwroot:/var/www
environment:
ENABLE_CRONTAB: "true"
TZ: ${TZ}
restart: on-failure
mysql:
container_name: mysql_lamine
image: "${MYSQL_VERSION}"
# command: --default-authentication-plugin=mysql_native_password
volumes:
# - ./etc/mysql/my.cnf:/etc/my.cnf
# - ./etc/mysql/my.cnf.d:/etc/my.cnf.d
- ./data/mysql/databases:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_ROOT_HOST: "%"
TZ: ${TZ}
restart: on-failure
phpmyadmin:
container_name: phpmyadmin_lamine
image: "${PMA_VERSION}"
ports:
- 8081:80
depends_on:
- mysql
environment:
PMA_HOST: mysql
TZ: ${TZ}
restart: on-failure
# redis:
# image: "${REDIS_VERSION}"
# volumes:
# - ./data/redis/data:/data:rw
# environment:
# TZ: ${TZ}
# restart: on-failure
+34
View File
@@ -0,0 +1,34 @@
# from docker mysql/mysql-server:8.0.18
#
# For advice on how to change settings please see
# http://dev.mysql.com/doc/refman/8.0/en/server-configuration-defaults.html
[mysqld]
#
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
#
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin
#
# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M
# Remove leading # to revert to previous value for default_authentication_plugin,
# this will increase compatibility with older clients. For background, see:
# https://dev.mysql.com/doc/refman/8.0/en/server-system-variables.html#sysvar_default_authentication_plugin
# default-authentication-plugin=mysql_native_password
skip-host-cache
skip-name-resolve
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
secure-file-priv=/var/lib/mysql-files
user=mysql
pid-file=/var/run/mysqld/mysqld.pid
View File
+22
View File
@@ -0,0 +1,22 @@
server {
listen 80;
listen 443 http2;
server_name localhost;
root /var/www/html/web;
index index.php;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass php-fpm:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
}
}
+33
View File
@@ -0,0 +1,33 @@
# from docker metowolf/nginx:1.17.5
user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
sendfile on;
#tcp_nopush on;
keepalive_timeout 65;
#gzip on;
include /etc/nginx/conf.d/*.conf;
}
+22
View File
@@ -0,0 +1,22 @@
-----BEGIN CERTIFICATE-----
MIIDpDCCAowCCQCUijlqpakSMjANBgkqhkiG9w0BAQsFADCBkjELMAkGA1UEBhMC
Q04xEjAQBgNVBAgMCUd1YW5nZG9uZzERMA8GA1UEBwwIU2hlbnpoZW4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bpE5QjKWzU6WECgYEA5TgVAFPT6yuVSQSc7OtvjrppvP/UCzJT
rVoV1OOhxu1rVKgbmhg/lP0jw4NbqEIaSzau+VngNAHkA0Tvqvtd+hSRmXciazXP
Nwmc6nVAEQh5mKujqAaGJhp72d7sYqyHLYumJU9euNp2P3/yOOWD3OWR9cHvHzvt
PBAuzWqpXPkCgYAe2C3Rl8U4KYxFGzi8/OKb9+6rfNn34gTWMqX7+FYbxbj3M+hx
Jom5dS1N119rW6s+3Y6hWA/oHP0rw5m9iAfkvR35MidaJD2SaNZfLs9uP3DsQzrC
4OeCA41zv0WnYn9NXzVAl0Ua4GpkiZkMY19/OtS3bVsehhwW+tuAEpe5oQKBgQCC
f0Y9lHv+1CY+lti8bWFqsahHSKKw6SsIc1QgiqPsu/gyDy7/sLRqHyAATEWfalrL
3UsKfOeO1FC6p8GG52reWF14MIIw5Uaef+OM+8nIqLmJeJZIr8Yp5UQDis2rc6vV
+z5Q2XoE5aMSjcYaLFjBJxXNA2cesiBi5JewrPvVCQKBgQCoGZEMwFkhvaLAJzMV
RhdzwZaC7X1TlG1WY0UcC1W16GLQgBfOmGpa7PvIX7DsztEWtBrxZ1j4evBrd+Fw
f2zEPDEkTLos3gUUizMnzfY2og2pxTmVbvy1RLP9aqRyaNaCz7omKTCwrLL1LpuP
vXL7jCwgfO65nucYH3wNBw7e/w==
-----END PRIVATE KEY-----
+150
View File
@@ -0,0 +1,150 @@
;;;;;;;;;;;;;;;;;;;;;
; FPM Configuration ;
;;;;;;;;;;;;;;;;;;;;;
; All relative paths in this configuration file are relative to PHP's install
; prefix (/usr/local). This prefix can be dynamically changed by using the
; '-p' argument from the command line.
;;;;;;;;;;;;;;;;;;
; Global Options ;
;;;;;;;;;;;;;;;;;;
[global]
; Pid file
; Note: the default prefix is /usr/local/var
; Default Value: none
;pid = run/php-fpm.pid
; Error log file
; If it's set to "syslog", log is sent to syslogd instead of being written
; into a local file.
; Note: the default prefix is /usr/local/var
; Default Value: log/php-fpm.log
;error_log = log/php-fpm.log
; syslog_facility is used to specify what type of program is logging the
; message. This lets syslogd specify that messages from different facilities
; will be handled differently.
; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON)
; Default Value: daemon
;syslog.facility = daemon
; syslog_ident is prepended to every message. If you have multiple FPM
; instances running on the same server, you can change the default value
; which must suit common needs.
; Default Value: php-fpm
;syslog.ident = php-fpm
; Log level
; Possible Values: alert, error, warning, notice, debug
; Default Value: notice
;log_level = notice
; Log limit on number of characters in the single line (log entry). If the
; line is over the limit, it is wrapped on multiple lines. The limit is for
; all logged characters including message prefix and suffix if present. However
; the new line character does not count into it as it is present only when
; logging to a file descriptor. It means the new line character is not present
; when logging to syslog.
; Default Value: 1024
;log_limit = 4096
; Log buffering specifies if the log line is buffered which means that the
; line is written in a single write operation. If the value is false, then the
; data is written directly into the file descriptor. It is an experimental
; option that can potentionaly improve logging performance and memory usage
; for some heavy logging scenarios. This option is ignored if logging to syslog
; as it has to be always buffered.
; Default value: yes
;log_buffering = no
; If this number of child processes exit with SIGSEGV or SIGBUS within the time
; interval set by emergency_restart_interval then FPM will restart. A value
; of '0' means 'Off'.
; Default Value: 0
;emergency_restart_threshold = 0
; Interval of time used by emergency_restart_interval to determine when
; a graceful restart will be initiated. This can be useful to work around
; accidental corruptions in an accelerator's shared memory.
; Available Units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
;emergency_restart_interval = 0
; Time limit for child processes to wait for a reaction on signals from master.
; Available units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
;process_control_timeout = 0
; The maximum number of processes FPM will fork. This has been designed to control
; the global number of processes when using dynamic PM within a lot of pools.
; Use it with caution.
; Note: A value of 0 indicates no limit
; Default Value: 0
; process.max = 128
; Specify the nice(2) priority to apply to the master process (only if set)
; The value can vary from -19 (highest priority) to 20 (lowest priority)
; Note: - It will only work if the FPM master process is launched as root
; - The pool process will inherit the master process priority
; unless specified otherwise
; Default Value: no set
; process.priority = -19
; Send FPM to background. Set to 'no' to keep FPM in foreground for debugging.
; Default Value: yes
;daemonize = yes
; Set open file descriptor rlimit for the master process.
; Default Value: system defined value
;rlimit_files = 1024
; Set max core size rlimit for the master process.
; Possible Values: 'unlimited' or an integer greater or equal to 0
; Default Value: system defined value
;rlimit_core = 0
; Specify the event mechanism FPM will use. The following is available:
; - select (any POSIX os)
; - poll (any POSIX os)
; - epoll (linux >= 2.5.44)
; - kqueue (FreeBSD >= 4.1, OpenBSD >= 2.9, NetBSD >= 2.0)
; - /dev/poll (Solaris >= 7)
; - port (Solaris >= 10)
; Default Value: not set (auto detection)
;events.mechanism = epoll
; When FPM is built with systemd integration, specify the interval,
; in seconds, between health report notification to systemd.
; Set to 0 to disable.
; Available Units: s(econds), m(inutes), h(ours)
; Default Unit: seconds
; Default value: 10
;systemd_interval = 10
;;;;;;;;;;;;;;;;;;;;
; Pool Definitions ;
;;;;;;;;;;;;;;;;;;;;
; Multiple pools of child processes may be started with different listening
; ports and different management options. The name of the pool will be
; used in logs and stats. There is no limitation on the number of pools which
; FPM can handle. Your system will tell you anyway :)
; Include one or more files. If glob(3) exists, it is used to include a bunch of
; files from a glob(3) pattern. This directive can be used everywhere in the
; file.
; Relative path can also be used. They will be prefixed by:
; - the global prefix if it's been set (-p argument)
; - /usr/local otherwise
include=etc/php-fpm.d/*.conf
max_execution_time = 600
max_input_time = 600
memory_limit = 2500M
post_max_size = 0
upload_max_filesize = 256M
+317140
View File
File diff suppressed because it is too large Load Diff
+17764
View File
File diff suppressed because it is too large Load Diff