Skip to content

Instantly share code, notes, and snippets.

@thomas-kl1
Created February 9, 2023 20:36
Show Gist options
  • Select an option

  • Save thomas-kl1/d4087c45e85f0e16337409c51cf2de6b to your computer and use it in GitHub Desktop.

Select an option

Save thomas-kl1/d4087c45e85f0e16337409c51cf2de6b to your computer and use it in GitHub Desktop.

Revisions

  1. thomas-kl1 created this gist Feb 9, 2023.
    37 changes: 37 additions & 0 deletions docker-compose.yml
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,37 @@
    version: '3.3'

    services:
    php:
    build:
    context: .
    dockerfile: dockerfile
    container_name: php81
    depends_on:
    - db
    image: php:8.1-apache
    volumes:
    - ./:/var/www/html/
    ports:
    - 8080:80
    db:
    container_name: mysql8
    image: mysql:8.0
    command: --default-authentication-plugin=mysql_native_password
    environment:
    MYSQL_ROOT_PASSWORD: root
    MYSQL_DATABASE: mydatabase
    MYSQL_USER: root
    MYSQL_PASSWORD: root
    ports:
    - 3306:3306
    pma:
    image: phpmyadmin/phpmyadmin:latest
    container_name: phpmyadmin
    environment:
    PMA_ARBITRARY: 1
    PMA_HOST: db
    PMA_USER: root
    PMA_PASSWORD: root
    UPLOAD_LIMIT: 20M
    ports:
    - 8899:80