From 6f912105431fd04fd98303dc9cd06fd9d5086bb4 Mon Sep 17 00:00:00 2001 From: letrhee Date: Wed, 25 Aug 2021 01:14:36 +0900 Subject: [PATCH 1/2] php-with-node. bullseye --- hidche/app/Dockerfile | 9 ++- hidche/board/Dockerfile | 4 +- hidche/example.docker-compose.override.yml | 68 ++++++++++++++++++++++ 3 files changed, 77 insertions(+), 4 deletions(-) create mode 100644 hidche/example.docker-compose.override.yml diff --git a/hidche/app/Dockerfile b/hidche/app/Dockerfile index 6acf35e..5d8a021 100644 --- a/hidche/app/Dockerfile +++ b/hidche/app/Dockerfile @@ -1,4 +1,4 @@ -FROM php:8.0-fpm-buster +FROM php:8.0-fpm-bullseye #debian ENV LC_ALL=C.UTF-8 @@ -8,7 +8,7 @@ RUN apt -y update ;\ bzip2 git rsync \ libmemcached-dev libcurl4-openssl-dev libmcrypt-dev \ libicu-dev libjpeg-dev libpng-dev libwebp-dev libfreetype6-dev \ - libzip-dev libxml2-dev libsqlite3-dev gosu; + libzip-dev libxml2-dev libsqlite3-dev gosu build-essential; RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ docker-php-ext-configure gd --with-freetype-dir=/usr --with-png-dir=/usr --with-jpeg-dir=/usr --with-webp-dir=/usr; \ @@ -24,6 +24,11 @@ RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ mysqli \ zip; RUN pecl install memcached mcrypt; + +RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash - && \ + apt install -yq nodejs +RUN npm install -g npm + #from nextcloud setting RUN mkdir -p /var/www/html/; \ mkdir -p /var/www/.ssh; diff --git a/hidche/board/Dockerfile b/hidche/board/Dockerfile index 8978d91..d8610b0 100644 --- a/hidche/board/Dockerfile +++ b/hidche/board/Dockerfile @@ -1,4 +1,4 @@ -FROM php:7.4-fpm-buster +FROM php:7.4-fpm-bullseye #debian ENV LC_ALL=C.UTF-8 @@ -8,7 +8,7 @@ RUN apt -y update ;\ bzip2 git rsync \ libmemcached-dev libcurl4-openssl-dev libmcrypt-dev \ libicu-dev libjpeg-dev libpng-dev libwebp-dev libfreetype6-dev \ - libzip-dev libxml2-dev libsqlite3-dev gosu; + libzip-dev libxml2-dev libsqlite3-dev gosu build-essential; RUN debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \ docker-php-ext-configure gd --with-freetype-dir=/usr --with-png-dir=/usr --with-jpeg-dir=/usr --with-webp-dir=/usr; \ diff --git a/hidche/example.docker-compose.override.yml b/hidche/example.docker-compose.override.yml new file mode 100644 index 0000000..5257ac6 --- /dev/null +++ b/hidche/example.docker-compose.override.yml @@ -0,0 +1,68 @@ +version: '3.2' + +services: + db: + ports: + - 3306:3306 + #For DEV. Expose MySQL port + volumes: + - type: bind + source: ~/dev_sam/db + target: /var/lib/mysql + + web: + build: + args: + UID: 1000 + GID: 1000 + #For DEV. Set UID of www-data as first local user + ports: + - 8084:80 + #For DEV. Export Web port. + volumes: + - type: bind + source: ~/dev_sam/app + target: /var/www/html + #For DEV. Set app path as local directory + - type: bind + source: ~/dev_sam/bbs + target: /var/www/board + + app: + build: + args: + UID: 1000 + GID: 1000 + volumes: + - type: bind + source: ~/dev_sam/app + target: /var/www/html + + board: + build: + args: + UID: 1000 + GID: 1000 + volumes: + - type: bind + source: ~/dev_sam/board + target: /var/www/board + + install: + volumes: + - type: bind + source: ~/dev_sam/app + target: /var/www/html + + cron: + build: ./cron + restart: "no" + #For DEV. Disable cron + entrypoint: ["echo", "Service cron disabled"] + + volumes: + - type: bind + source: ~/dev_sam/app + target: /var/www/html + depends_on: + - app -- 2.54.0 From 9b1fc5bd1d78fe30e20508a0c7dee70fffff1f57 Mon Sep 17 00:00:00 2001 From: Hide_D Date: Thu, 9 Sep 2021 23:23:03 +0900 Subject: [PATCH 2/2] =?UTF-8?q?webpack=20=EB=8C=80=EA=B8=B0=EC=9A=A9=20tim?= =?UTF-8?q?eout=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hidche/web/default.conf | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hidche/web/default.conf b/hidche/web/default.conf index 56abf98..6fdd3f0 100644 --- a/hidche/web/default.conf +++ b/hidche/web/default.conf @@ -32,13 +32,14 @@ server { location / { location ~ \.php$ { include fastcgi_params; + proxy_read_timeout 600; fastcgi_pass app:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; } } - + # deny access to .htaccess files, if Apache's document root # concurs with nginx's one -- 2.54.0