Skip to content

Instantly share code, notes, and snippets.

@jackmakiyama
Created April 6, 2017 20:07
Show Gist options
  • Save jackmakiyama/2139ff80c61996beffae33a7bd19ba0c to your computer and use it in GitHub Desktop.
Save jackmakiyama/2139ff80c61996beffae33a7bd19ba0c to your computer and use it in GitHub Desktop.
<VirtualHost *:80>
ServerName test.local;
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/public
<Directory /var/www/html/public>
Options -Indexes +FollowSymLinks +MultiViews
AllowOverride All
Require all granted
php_value date.timezone "America/Cuiaba"
</Directory>
</VirtualHost>
web:
build: ./docker
ports:
- "80:80"
hostname: test.local
volumes:
- .:/var/www/html/
- ./docker/apache:/etc/apache2/sites-enabled
- ./docker/xdebug.ini:/usr/local/etc/php/conf.d/xdebug.ini
links:
- db:db
db:
image: mysql:5.6
ports:
- "3306:3306"
environment:
MYSQL_ROOT_PASSWORD: test
MYSQL_USER: test
MYSQL_PASSWORD: test
MYSQL_DATABASE: test
FROM php:7-apache
RUN buildDeps="libpq-dev libzip-dev libicu-dev" && \
apt-get update && \
apt-get install -y $buildDeps --no-install-recommends && \
rm -rf /var/lib/apt/lists/* && \
docker-php-ext-install \
mysqli \
pdo_mysql \
mbstring \
intl
RUN a2enmod rewrite
RUN pecl install -o -f xdebug \
&& rm -rf /tmp/pear
RUN service apache2 restart
zend_extension=xdebug.so
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_port=9000
xdebug.remote_autostart=1
xdebug.remote_connect_back=0
xdebug.idekey=docker
xdebug.remote_host=192.168.1.16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment