meta data for this page
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| wiki:docker:compose-cookbook [2022/06/14 06:46] – created mchus | wiki:docker:compose-cookbook [2022/06/20 06:17] (current) – mchus | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | ====== Docker Compose Cook Book ====== | ||
| + | {{tag> | ||
| + | ===== nextcloud ===== | ||
| + | <code yaml> | ||
| + | version: ' | ||
| + | |||
| + | services: | ||
| + | db: | ||
| + | image: mariadb | ||
| + | restart: always | ||
| + | command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW | ||
| + | volumes: | ||
| + | - type: bind | ||
| + | | ||
| + | | ||
| + | |||
| + | environment: | ||
| + | - MYSQL_ROOT_PASSWORD=$MYSQL_ROOT_PASSWORD | ||
| + | - MYSQL_PASSWORD=$MYSQL_PASSWORD | ||
| + | - MYSQL_DATABASE=$MYSQL_DATABASE | ||
| + | - MYSQL_USER=$MYSQL_USER | ||
| + | |||
| + | app: | ||
| + | image: nextcloud: | ||
| + | restart: always | ||
| + | links: | ||
| + | - db | ||
| + | volumes: | ||
| + | - type: bind | ||
| + | | ||
| + | | ||
| + | environment: | ||
| + | - MYSQL_PASSWORD=$MYSQL_PASSWORD | ||
| + | - MYSQL_DATABASE=$MYSQL_DATABASE | ||
| + | - MYSQL_USER=$MYSQL_USER | ||
| + | - MYSQL_HOST=db | ||
| + | |||
| + | web: | ||
| + | image: nginx | ||
| + | restart: always | ||
| + | ports: | ||
| + | - 8080:80 | ||
| + | links: | ||
| + | - app | ||
| + | volumes: | ||
| + | - type: bind | ||
| + | | ||
| + | | ||
| + | volumes_from: | ||
| + | - app | ||
| + | </ | ||