Skip to content

Instantly share code, notes, and snippets.

@mohamednizar
Created November 8, 2018 10:33
Show Gist options
  • Save mohamednizar/aced5645f2fe2586145d119c4e87b601 to your computer and use it in GitHub Desktop.
Save mohamednizar/aced5645f2fe2586145d119c4e87b601 to your computer and use it in GitHub Desktop.
Deploy nginx app with docker
docker build -t nginx_image .
# Dockerfile for a php:7.2-apache container
# Place this file inside the project folder
FROM phpearth/php:7.2-nginx
RUN apk add --no-cache php7.2-sodium php7.2-intl php7.2-pdo_mysql \
&& apk add --no-cache php7-mysqli mysql
RUN apk add --no-cache phpunit
RUN apk add --no-cache composer
ADD . /var/www/html
WORKDIR /var/www/html
RUN sed -ri 's/^www-data:x:82:82:/www-data:x:1000:50:/' /etc/passwd
EXPOSE 80
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment