Add base Dockerfile for Dockerhub builds (#504)
This commit is contained in:
parent
c2f7c5e421
commit
6fcbd603ba
1
.dockerignore
Normal file
1
.dockerignore
Normal file
@ -0,0 +1 @@
|
|||||||
|
vendor
|
@ -50,6 +50,7 @@ if [ "$TRAVIS" = "true" ]; then
|
|||||||
.travis
|
.travis
|
||||||
docker
|
docker
|
||||||
_ide_helper.php
|
_ide_helper.php
|
||||||
|
.dockerignore
|
||||||
.dpl
|
.dpl
|
||||||
.editorconfig
|
.editorconfig
|
||||||
.eslintignore
|
.eslintignore
|
||||||
|
28
Dockerfile
Normal file
28
Dockerfile
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
FROM php:7.4-fpm-alpine
|
||||||
|
|
||||||
|
WORKDIR /var/www/
|
||||||
|
|
||||||
|
RUN apk add gmp-dev
|
||||||
|
RUN curl --silent --show-error https://getcomposer.org/installer | php
|
||||||
|
|
||||||
|
# Copy any config files in
|
||||||
|
COPY resources/docker/php/ext-opcache.ini $PHP_INI_DIR/conf.d/
|
||||||
|
COPY resources/docker/php/www.conf /usr/local/etc/php-fpm.d/www.conf
|
||||||
|
RUN ln -sf /dev/stderr /var/log/fpm-error.log
|
||||||
|
|
||||||
|
RUN docker-php-ext-install \
|
||||||
|
calendar \
|
||||||
|
pdo_mysql \
|
||||||
|
gmp \
|
||||||
|
opcache && \
|
||||||
|
docker-php-ext-enable pdo_mysql opcache
|
||||||
|
|
||||||
|
COPY . /var/www/
|
||||||
|
RUN php composer.phar install \
|
||||||
|
--ignore-platform-reqs \
|
||||||
|
--no-interaction \
|
||||||
|
--no-plugins \
|
||||||
|
--no-scripts \
|
||||||
|
--prefer-dist
|
||||||
|
|
||||||
|
EXPOSE 9000
|
@ -2,8 +2,9 @@
|
|||||||
version: '3'
|
version: '3'
|
||||||
services:
|
services:
|
||||||
app:
|
app:
|
||||||
|
# For your own docker-compose, use `image: phpvms:latest` instead of the build/context block
|
||||||
build:
|
build:
|
||||||
context: ./resources/docker/php
|
context: .
|
||||||
environment:
|
environment:
|
||||||
DB_HOST: mysql
|
DB_HOST: mysql
|
||||||
REDIS_HOST: redis
|
REDIS_HOST: redis
|
||||||
|
@ -1,7 +1,5 @@
|
|||||||
FROM php:7.3-fpm-alpine
|
FROM php:7.3-fpm-alpine
|
||||||
|
|
||||||
#RUN apt-get update
|
|
||||||
#RUN apt-get install -y libgmp-dev
|
|
||||||
RUN apk add gmp-dev
|
RUN apk add gmp-dev
|
||||||
|
|
||||||
# Copy any config files in
|
# Copy any config files in
|
||||||
|
Loading…
Reference in New Issue
Block a user