Skip to content

Instantly share code, notes, and snippets.

@gukandrew
Created June 2, 2020 12:07
Show Gist options
  • Save gukandrew/2bd2eca52a0f27fa22090a4ca0744433 to your computer and use it in GitHub Desktop.
Save gukandrew/2bd2eca52a0f27fa22090a4ca0744433 to your computer and use it in GitHub Desktop.
MariaDB & phpMyAdmin on Alpine Linux using docker-compose.yml
################################################################################
# docker-compose file to run yobasystems/alpine-mariadb & phpmyadmin/phpmyadmin
#
# run with `docker-compose up -d`
# and connect on host using mysql command: `mysql -h127.0.0.1 -uroot -ppassword`
# or over phpMyAdmin http://localhost:8080/
#
# Author Andrew Guk
################################################################################
version: "3.8"
services:
db:
image: yobasystems/alpine-mariadb
working_dir: /var/lib/mysql
volumes:
- ./data:/var/lib/mysql
ports:
- "3306:3306"
environment:
MYSQL_ROOT_PASSWORD: password
phpmyadmin:
image: phpmyadmin/phpmyadmin
links:
- db
ports:
- "8080:80"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment