I'm trying to create a workflow in docker. It's simple: just PHP and MySQL to little tests.
My docker-compose.yml:
web:
build: .docker
links:
- mysql:mysql
ports:
- "80:80"
- "443:443"
volumes:
- ./public_html:/var/www/html
mysql:
image: mysql:5.7
environment:
- MYSQL_ROOT_PASSWORD=root
volumes:
- "./.data/db:/var/lib/mysql"
phpmyadmin:
image: phpmyadmin/phpmyadmin
ports:
- "8080:80"
links:
- mysql:mysql
environment:
- PMA_HOST=mysql
volumes:
- /sessions
And my Dockerfile:
FROM php:5.6-apache
RUN docker-php-ext-install mysqli
It's all ok: I can up containers but PHP itself cannot write in directories (like fwrite()
or similar).
I researched a lot and tried a lot of tutorials, but nothing...