docker-compose.yaml 653 Bytes
Newer Older
Anca Iordache's avatar
Anca Iordache committed
1
2
3
4
5
6
7
8
9
10
11
12
13
version: '3.7'
services:
  db:
    image: mysql:8.0.19
    command: '--default-authentication-plugin=mysql_native_password'
    volumes:
      - db_data:/var/lib/mysql
    restart: always
    environment:
      - MYSQL_ROOT_PASSWORD=somewordpress
      - MYSQL_DATABASE=wordpress
      - MYSQL_USER=wordpress
      - MYSQL_PASSWORD=wordpress
14
15
16
    expose:
      - 3306
      - 33060
Anca Iordache's avatar
Anca Iordache committed
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  wordpress:
    image: wordpress:latest
    ports:
      - 80:80
    restart: always
    environment:
      - WORDPRESS_DB_HOST=db
      - WORDPRESS_DB_USER=wordpress
      - WORDPRESS_DB_PASSWORD=wordpress
      - WORDPRESS_DB_NAME=wordpress
volumes:
  db_data: