top of page
  • Writer's pictureSID - President

Wordpress on DockerCompose

  wordpress:
    image: wordpress
    ports:
      - 8089:80
    depends_on:
      - mysql
    environment:
      WORDPRESS_DB_HOST: mysql
      WORDPRESS_DB_USER: root
      WORDPRESS_DB_PASSWORD: ${WORDPRESS_DB_PASSWORD}
      WORDPRESS_DB_NAME: wordpress
    restart: unless-stopped
  mysql:
    image: mysql
    environment:
      MYSQL_DATABASE: wordpress
      MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
    volumes:
      - ./mysql:/var/lib/mysql
    restart: unless-stopped
networks: {}

.env entry:

WORDPRESS_DB_PASSWORD=set your wordpress database password here
MYSQL_ROOT_PASSWORD=set your mysql root password here

15 views0 comments

Recent Posts

See All

Comments


bottom of page