add docker local dev stuff
This commit is contained in:
21
docker/Dockerfile
Normal file
21
docker/Dockerfile
Normal file
@@ -0,0 +1,21 @@
|
||||
FROM urre/wordpress-nginx-docker-compose-image:1.4.0
|
||||
|
||||
# PHP Extensions
|
||||
RUN docker-php-ext-configure calendar && docker-php-ext-install calendar
|
||||
|
||||
# Install wp-cli
|
||||
RUN apt-get update && apt-get install -y sudo less mariadb-client
|
||||
RUN curl -o /bin/wp-cli.phar https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
|
||||
RUN chmod +x /bin/wp-cli.phar
|
||||
RUN cd /bin && mv wp-cli.phar wp
|
||||
RUN mkdir -p /var/www/.wp-cli/cache && chown www-data:www-data /var/www/.wp-cli/cache
|
||||
|
||||
# Install composer
|
||||
COPY --from=composer:latest /usr/bin/composer /usr/local/bin/composer
|
||||
|
||||
# Forward Message to mailhog
|
||||
RUN curl --location --output /usr/local/bin/mhsendmail https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64 && \
|
||||
chmod +x /usr/local/bin/mhsendmail
|
||||
RUN echo 'sendmail_path="/usr/local/bin/mhsendmail --smtp-addr=mailhog:1025 --from=no-reply@gbp.lo"' > /usr/local/etc/php/conf.d/mailhog.ini
|
||||
|
||||
# Note: Use docker-compose up -d --force-recreate --build when Dockerfile has changed.
|
||||
Reference in New Issue
Block a user