Created
August 29, 2016 06:59
-
-
Save 63phc/1edd9c19c9501d2f7cb7b0354a0b5067 to your computer and use it in GitHub Desktop.
Docker
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| php-fpm --allow-to-run-as-root |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| example.com { | |
| root ./public | |
| fastcgi / php:9000 php | |
| rewrite { | |
| to {path} {path}/ /index.php?{query} | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ########################################################### | |
| # MAINTAINER: Aioslike <[email protected]> # | |
| ########################################################### | |
| # Example Config #---------------------------------- | |
| version: "2" | |
| services: | |
| php: | |
| image: "example-image" | |
| container_name: "samplephp" | |
| volumes: | |
| - .:/srv | |
| command: ['bash', 'boot.sh'] | |
| caddy: | |
| image: "abiosoft/caddy" | |
| container_name: "samplename" | |
| ports: | |
| - 443:443 | |
| - 80:80 | |
| volumes: | |
| - ./Caddyfile:/etc/Caddyfile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM php:7.0-fpm | |
| RUN apt-get update && \ | |
| apt-get install -y libmcrypt-dev \ | |
| libpq-dev \ | |
| libpng-dev \ | |
| libxml2-dev \ | |
| libxslt-dev \ | |
| libicu-dev \ | |
| libjpeg62-turbo-dev \ | |
| libfreetype6-dev \ | |
| libpng12-dev \ | |
| libbz2-dev && \ | |
| rm -rf /var/lib/apt/lists/* | |
| RUN docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ && \ | |
| docker-php-ext-install \ | |
| mcrypt \ | |
| bcmath \ | |
| mbstring \ | |
| zip \ | |
| opcache \ | |
| pdo \ | |
| pdo_mysql \ | |
| gd \ | |
| xmlrpc \ | |
| opcache \ | |
| intl \ | |
| mysqli \ | |
| bz2 \ | |
| json | |
| COPY . /srv | |
| WORKDIR /srv | |
| RUN sed -i 's/\r$//' boot.sh | |
| CMD ["/bin/bash", "boot.sh"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment