From 4b1e42354075eb827fe57f3491e66718b4dca9c4 Mon Sep 17 00:00:00 2001 From: Noel Palo Date: Thu, 25 Aug 2022 22:52:08 +0800 Subject: [PATCH] webstack/docker-nginx-php81-mysql80-no-laravel - Update ReadMe, Dockerfile, docker-compose, and config files - Update Php to version 8.1 - Update MySql to version 8.0.30 --- docker/containers/composer/Dockerfile | 4 ++-- docker/containers/mysql/Dockerfile | 2 +- docker/containers/php/Dockerfile | 6 +++--- docker/docker-compose.yml | 5 +++-- docker/environments/config.env | 2 +- 5 files changed, 10 insertions(+), 9 deletions(-) diff --git a/docker/containers/composer/Dockerfile b/docker/containers/composer/Dockerfile index e919338..ce12d37 100644 --- a/docker/containers/composer/Dockerfile +++ b/docker/containers/composer/Dockerfile @@ -1,7 +1,7 @@ # Pull from PHP from previous Dockerfile - php/Dockerfile # - see docker/docker-compose.yml for more info -# - use the image tag php:php-7.4-fpm-alpine -FROM php:php-7.4-fpm-alpine +# - use the image tag php:php-8.1-fpm-alpine +FROM php:php-8.1-fpm-alpine # Install Composer 2.1.5 RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer --version=2.1.5 diff --git a/docker/containers/mysql/Dockerfile b/docker/containers/mysql/Dockerfile index 03ca982..eb91790 100644 --- a/docker/containers/mysql/Dockerfile +++ b/docker/containers/mysql/Dockerfile @@ -1,2 +1,2 @@ # Install MySQL -FROM library/mysql:5.7.22 +FROM library/mysql:8.0.30 diff --git a/docker/containers/php/Dockerfile b/docker/containers/php/Dockerfile index 739be71..f8ccf40 100644 --- a/docker/containers/php/Dockerfile +++ b/docker/containers/php/Dockerfile @@ -1,7 +1,7 @@ -# Install PHP 7.4 -FROM php:7.4-fpm-alpine +# Install PHP 8.1 +FROM php:8.1-fpm-alpine # Install PHP Extension RUN apk --no-cache add zip libzip-dev \ && docker-php-ext-configure zip \ - && docker-php-ext-install zip pdo pdo_mysql + && docker-php-ext-install zip pdo pdo_mysql \ diff --git a/docker/docker-compose.yml b/docker/docker-compose.yml index 9d50ecb..ad23212 100644 --- a/docker/docker-compose.yml +++ b/docker/docker-compose.yml @@ -31,10 +31,11 @@ services: networks: - web-app container_name: mysql + command: mysqld --default-authentication-plugin=mysql_native_password build: context: . dockerfile: containers/mysql/Dockerfile - image: mysql:mysql-5.7.22 + image: mysql:mysql-8.0.30 restart: unless-stopped tty: true ports: @@ -61,7 +62,7 @@ services: build: context: . dockerfile: containers/php/Dockerfile - image: php:php-7.4-fpm-alpine + image: php:php-8.1-fpm-alpine ports: - "9000:9000" volumes: diff --git a/docker/environments/config.env b/docker/environments/config.env index 0761f7d..201d2f4 100644 --- a/docker/environments/config.env +++ b/docker/environments/config.env @@ -14,6 +14,6 @@ PATH_DATABASE=./volumes/mysql # DATABASE DB_DRIVER=mysql -DB_VERSION=5.7.22 +DB_VERSION=8.0.30 DB_PORT=3306 DB_VOLUME=${PATH_DATABASE}/${DB_DRIVER}_${DB_VERSION} \ No newline at end of file