docker-compose up
If you don't need zip functionality (like for Duplicator), in the compose file, comment out the build line and uncomment the image line.
| version: '2' | |
| services: | |
| wordpress: | |
| build: . | |
| # image: wordpress | |
| ports: | |
| - 80:80 | |
| environment: | |
| WORDPRESS_DB_PASSWORD: root | |
| volumes: | |
| - "./wp:/var/www/html" | |
| mysql: | |
| image: mariadb | |
| environment: | |
| MYSQL_ROOT_PASSWORD: root | |
| volumes: | |
| - "./db:/var/lib/mysql" |
| FROM wordpress | |
| RUN apt-get update && apt-get install -y zlib1g-dev && rm -rf /var/lib/apt/lists/* && docker-php-ext-install zip |