Compare commits

..

14 Commits

Author SHA1 Message Date
7b3108da85 ssrc_d9 new commit 2025-04-11 10:38:09 +02:00
2106517adb removed d7 containers 2025-04-11 10:04:02 +02:00
5ff1cd63d2 src_d9 new commits 2025-03-10 11:40:30 +01:00
20ea6838c7 updated gitmodules urls 2025-03-10 11:34:57 +01:00
0fb5595a07 src_d9 update 2024-02-01 10:47:41 +01:00
becdab47fd make file bug fix 2024-01-31 21:37:06 +01:00
da696eee06 updated all minors and major version of modules, perparing for drupal core upgrade to 10 2024-01-31 21:27:28 +01:00
a01a2db696 modified bashrc php version 2024-01-31 17:06:45 +01:00
2fde89b394 updated src_d9 2024-01-31 14:37:04 +01:00
2425dc7881 some cleaning 2023-10-31 16:20:43 +01:00
78ebe8af17 app update 2023-03-27 11:46:54 +02:00
a1c051983d updated php to 8.1 2023-03-27 11:10:41 +02:00
a6ff31a2a2 updated src_d9 2022-08-17 18:34:18 +02:00
5872e1d879 fixed xdebug 2022-08-17 18:34:00 +02:00
13 changed files with 132 additions and 93 deletions

4
.gitmodules vendored
View File

@@ -1,6 +1,6 @@
[submodule "src_d7"] [submodule "src_d7"]
path = src_d7 path = src_d7
url = https://figureslibres.io/gogs/bachir/popsu-d7.git url = https://figureslibres.io/gitea/bachir/popsu-d7.git
[submodule "src_d9"] [submodule "src_d9"]
path = src_d9 path = src_d9
url = https://figureslibres.io/gogs/bachir/popsu-d9.git url = https://figureslibres.io/gitea/bachir/popsu-d9.git

View File

@@ -1,40 +1,40 @@
server { # server {
listen 80; # listen 80;
root /var/www/d7; # root /var/www/d7;
index index.html index.php; # index index.html index.php;
server_name dev.d7.popsu.archi.fr; # server_name dev.d7.popsu.archi.fr;
charset utf-8; # charset utf-8;
location / { # location / {
try_files $uri $uri/ /index.php?$query_string; # try_files $uri $uri/ /index.php?$query_string;
} # }
location = /favicon.ico { access_log off; log_not_found off; } # location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt { access_log off; log_not_found off; } # location = /robots.txt { access_log off; log_not_found off; }
access_log on; # access_log on;
error_log /var/log/nginx/error-d7.log error; # error_log /var/log/nginx/error-d7.log error;
sendfile off; # sendfile off;
client_max_body_size 100m; # client_max_body_size 100m;
location ~ \.php$ { # location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$; # fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass php_d7:9000; # fastcgi_pass php_d7:9000;
fastcgi_index index.php; # fastcgi_index index.php;
include fastcgi_params; # include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; # fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_intercept_errors off; # fastcgi_intercept_errors off;
fastcgi_buffer_size 16k; # fastcgi_buffer_size 16k;
fastcgi_buffers 4 16k; # fastcgi_buffers 4 16k;
} # }
location ~ /\.ht { # location ~ /\.ht {
deny all; # deny all;
} # }
} # }
server { server {
listen 80; listen 80;

View File

@@ -1,4 +1,4 @@
FROM php:7.4-fpm FROM php:8.1-fpm
RUN apt-get update && apt-get install -y \ RUN apt-get update && apt-get install -y \
libfreetype6-dev \ libfreetype6-dev \
@@ -7,6 +7,8 @@ RUN apt-get update && apt-get install -y \
libpng-dev \ libpng-dev \
mariadb-client \ mariadb-client \
zip \ zip \
iputils-ping \
iproute2 \
libzip-dev && \ libzip-dev && \
# docker-php-ext-install -j$(nproc) iconv && \ # docker-php-ext-install -j$(nproc) iconv && \
docker-php-ext-configure gd --with-freetype --with-jpeg && \ docker-php-ext-configure gd --with-freetype --with-jpeg && \
@@ -20,8 +22,10 @@ RUN apt-get update && apt-get install -y \
RUN apt-get install -y git vim RUN apt-get install -y git vim
RUN pecl install redis-5.3.3 && \ RUN pecl install redis-5.3.3 && \
pecl install xdebug-2.9.2 && \ docker-php-ext-enable redis
docker-php-ext-enable redis xdebug
RUN pecl install xdebug-3.3.1 && \
docker-php-ext-enable xdebug
RUN export COMPOSER_HOME=/usr/local/composer && \ RUN export COMPOSER_HOME=/usr/local/composer && \
curl -sS https://getcomposer.org/installer \ curl -sS https://getcomposer.org/installer \
@@ -33,13 +37,6 @@ RUN export COMPOSER_HOME=/usr/local/composer && \
-L -o /usr/local/bin/drush && \ -L -o /usr/local/bin/drush && \
chmod +x /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
RUN apt-get install -y rsyslog RUN apt-get install -y rsyslog
COPY ./rsyslog-drupal.conf /etc/rsyslog.d/drupal.conf COPY ./rsyslog-drupal.conf /etc/rsyslog.d/drupal.conf
# ENTRYPOINT ["sh", "-c", "service rsyslog start ; tail -f /dev/null"] # ENTRYPOINT ["sh", "-c", "service rsyslog start ; tail -f /dev/null"]

View File

@@ -1,4 +1,4 @@
PS1='\e[36m\e[1mPHP-7.4\e[0m:\e[90m\w\e[0m\n$ ' PS1='\e[36m\e[1mPHP-8.1\e[0m:\e[90m\w\e[0m\n$ '
bind '"\e[A": history-search-backward' bind '"\e[A": history-search-backward'
bind '"\e[B": history-search-forward' bind '"\e[B": history-search-forward'

View File

@@ -24,6 +24,12 @@ build:
buildnc: buildnc:
docker-compose build --no-cache --build-arg USER_UID=$(USER_UID) --build-arg USER_UNAME=$(USER_UNAME) --build-arg USER_GID=$(USER_GID) --build-arg USER_GNAME=$(USER_GNAME) docker-compose build --no-cache --build-arg USER_UID=$(USER_UID) --build-arg USER_UNAME=$(USER_UNAME) --build-arg USER_GID=$(USER_GID) --build-arg USER_GNAME=$(USER_GNAME)
buildnc_php_d9:
docker-compose build --no-cache --build-arg USER_UID=$(USER_UID) --build-arg USER_UNAME=$(USER_UNAME) --build-arg USER_GID=$(USER_GID) --build-arg USER_GNAME=$(USER_GNAME) php_d9
buildncnginx:
docker-compose build --no-cache --build-arg USER_UID=$(USER_UID) --build-arg USER_UNAME=$(USER_UNAME) --build-arg USER_GID=$(USER_GID) --build-arg USER_GNAME=$(USER_GNAME) nginx
downbuildup: down build up downbuildup: down build up
up: up:
@@ -67,20 +73,20 @@ down:
exec_nginx: exec_nginx:
docker exec -it popsu-nginx-1 bash docker exec -it popsu-nginx-1 bash
exec_php_d7: # exec_php_d7:
docker exec -it popsu-php_d7-1 bash # docker exec -it popsu-php_d7-1 bash
exec_php_d9: exec_php_d9:
docker exec -it popsu-php_d9-1 bash docker exec -it popsu-php_d9-1 bash
exec_mysql_d7: # exec_mysql_d7:
docker exec -it popsu-mysql_d7-1 bash # docker exec -it popsu-mysql_d7-1 bash
exec_mysql_d9: exec_mysql_d9:
docker exec -it popsu-mysql_d9-1 bash docker exec -it popsu-mysql_d9-1 bash
dump_d7_db: # dump_d7_db:
docker exec popsu-mysql_d7-1 sh -c 'exec mysqldump -uroot -ppopsu popsu-d7' > ./ressources/popsu-d7-$(DATE_NOW)-local.sql # docker exec popsu-mysql_d7-1 sh -c 'exec mariadb-dump -uroot -ppopsu popsu-d7' > ./ressources/popsu-d7-$(DATE_NOW)-local.sql
dump_d9_db: dump_d9_db:
docker exec popsu-mysql_d9-1 sh -c 'exec mysqldump -uroot -ppopsu popsu-d9' > ./ressources/popsu-d9-$(DATE_NOW)-local.sql docker exec popsu-mysql_d9-1 sh -c 'exec mariadb-dump -uroot -ppopsu popsu_d9' > ./ressources/popsu-d9-$(DATE_NOW)-local.sql

View File

@@ -1,19 +1,19 @@
version: "3.5" version: "3.5"
services: services:
mysql_d7: # mysql_d7:
image: mariadb:latest # image: mariadb:latest
volumes: # volumes:
- db-data-d7:/var/lib/mysql # - db-data-d7:/var/lib/mysql
- ./Docker/mysql/mysql.cnf:/etc/mysql/conf.d/custom.cnf:ro # - ./Docker/mysql/mysql.cnf:/etc/mysql/conf.d/custom.cnf:ro
- "${DB_IMPORTE_FILE_D7}:/docker-entrypoint-initdb.d/popsu_d7.sql" # - "${DB_IMPORTE_FILE_D7}:/docker-entrypoint-initdb.d/popsu_d7.sql"
networks: # networks:
- database # - database
environment: # environment:
MYSQL_ROOT_PASSWORD: "${DB_ROOT_PASSWORD}" # MYSQL_ROOT_PASSWORD: "${DB_ROOT_PASSWORD}"
MYSQL_DATABASE: "${DB_NAME_D7}" # MYSQL_DATABASE: "${DB_NAME_D7}"
MYSQL_USER: "${DB_USERNAME}" # MYSQL_USER: "${DB_USERNAME}"
MYSQL_PASSWORD: "${DB_PASSWORD}" # MYSQL_PASSWORD: "${DB_PASSWORD}"
mysql_d9: mysql_d9:
image: mariadb:latest image: mariadb:latest
@@ -38,22 +38,22 @@ services:
ports: ports:
- "6379" - "6379"
php_d7: # php_d7:
build: ./Docker/php-5.6-fpm/ # build: ./Docker/php-5.6-fpm/
volumes: # volumes:
- php-d7-user-data:/home/${USER_UNAME} # - php-d7-user-data:/home/${USER_UNAME}
- "${PROJECT_ROOT_D7}:/var/www/d7" # - "${PROJECT_ROOT_D7}:/var/www/d7"
working_dir: "/var/www/d7" # working_dir: "/var/www/d7"
networks: # networks:
- database # - database
- server # - server
- redis # - redis
depends_on: # depends_on:
- mysql_d7 # - mysql_d7
- redis # - redis
php_d9: php_d9:
build: ./Docker/php-7.4-fpm/ build: ./Docker/php-8.1-fpm/
user: ${USER_UID}:${USER_GID} user: ${USER_UID}:${USER_GID}
volumes: volumes:
- php-d9-user-data:/home/${USER_UNAME} - php-d9-user-data:/home/${USER_UNAME}
@@ -66,6 +66,10 @@ services:
- database - database
- redis - redis
- server - server
# for xdebug
# https://github.com/docker/for-linux/issues/264#issuecomment-965465879
extra_hosts:
- "host.docker.internal:host-gateway"
depends_on: depends_on:
- mysql_d9 - mysql_d9
- redis - redis
@@ -77,10 +81,10 @@ services:
networks: networks:
- database - database
depends_on: depends_on:
- mysql_d7 # - mysql_d7
- mysql_d9 - mysql_d9
environment: environment:
PMA_HOSTS: mysql_d7,mysql_d9 PMA_HOSTS: mysql_d9 #mysql_d7,
nginx: nginx:
@@ -89,20 +93,20 @@ services:
- 8980:80 - 8980:80
working_dir: "/var/www" working_dir: "/var/www"
volumes: volumes:
- "${PROJECT_ROOT_D7}:/var/www/d7" # - "${PROJECT_ROOT_D7}:/var/www/d7"
- "${PROJECT_ROOT_D9}:/var/www/d9" - "${PROJECT_ROOT_D9}:/var/www/d9"
- "${LOG_ROOT}:/var/log:rw" - "${LOG_ROOT}:/var/log:rw"
networks: networks:
- server - server
depends_on: depends_on:
- php_d7 # - php_d7
- php_d9 - php_d9
volumes: volumes:
db-data-d7: # db-data-d7:
db-data-d9: db-data-d9:
redis-data: redis-data:
php-d7-user-data: # php-d7-user-data:
php-d9-user-data: php-d9-user-data:
networks: networks:

View File

@@ -1,18 +1,50 @@
[xdebug] [xdebug]
xdebug.remote_enable=1 ; xdebug.remote_enable=1
xdebug.mode=debug
;Should use host.docker.internal but not working on linux ;Should use host.docker.internal but not working on linux
xdebug.remote_host=172.21.0.1 ; xdebug.remote_host=172.20.0.1
; Replaced by xdebug.client_host.
xdebug.client_host=host.docker.internal
;Not working on docker context ;Not working on docker context
xdebug.remote_connect_back=0 ; xdebug.remote_connect_back=0
; Replaced by xdebug.discover_client_host.
xdebug.discover_client_host=0
;9000 is already bound by php-fpm ;9000 is already bound by php-fpm
xdebug.remote_port=9001 ; xdebug.remote_port=9001
; xdebug.remote_port #
; Replaced by xdebug.client_port.
; The default value has also changed from 9000 to 9003.
xdebug.client_port=9001
xdebug.remote_handler=dbgp xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_autostart=true ; xdebug.remote_mode=req
; xdebug.remote_mode #
; For the req value (the original default), use xdebug.mode=debug with xdebug.start_with_request=trigger. If the original xdebug.remote_autostart behaviour is necessary, use xdebug.start_with_request=yes instead of trigger.
; For the jit value, use xdebug.mode=debug and xdebug.start_upon_error=yes.
; xdebug.remote_autostart=true
; Use xdebug.mode=debug with xdebug.start_with_request=yes
xdebug.start_with_request=yes
; ?=XDEBUG_SESSION_START=1 ; ?=XDEBUG_SESSION_START=1
;Log file is mounted on volume so you can follow it ;Log file is mounted on volume so you can follow it
xdebug.remote_log=/var/log/xdebug-error.log ; xdebug.remote_log=/var/log/xdebug-error.log
xdebug.profiler_enable_trigger=1 ; Replaced by xdebug.log, which also includes log messages beyond Step Debugging.
xdebug.profiler_enable=0 xdebug.log=/var/log/xdebug-error.log
xdebug.profiler_output_dir=/var/log/
; xdebug.profiler_enable=0
; xdebug.profiler_enable_trigger=1
; Use xdebug.mode=profile with xdebug.start_with_request=trigger.
xdebug.profiler_output_name = cachegrind.out.%t.%R
xdebug.output_dir=/var/log/
; Use the generic xdebug.output_dir setting.
; Example: http://localhost:8080/test?XDEBUG_PROFILE=1 ; Example: http://localhost:8080/test?XDEBUG_PROFILE=1

2
src_d9

Submodule src_d9 updated: fa8d7c4347...bded893630