In this tutorial we learn how to Install Phpmyadmin on Ubuntu 20.04 using Docker
Prerequisites
Docker
Mysql
Connect docker phpmyadmin with mysql database
1. Go to https://hub.docker.com/r/phpmyadmin/p...
2. Pull latest phpmyadmin docker image
3. Create docker compose file for phpmyadmin. Name it as docker-compose-phpmyadmin.yml.
4. Check you local ip address with command ifconfig
5. Edit docker-compose-phpmyadmin.yml and add ip address under environment variable PMA_HOSTS
6. Run the docker image with the compose file
docker-compose -f docker-compose-phpmyadmin.yml up -d
7. Check docker logs
docker logs -f container-id
8. Access phpmyadmin with http://localhost:8080/.
Give username password
Run phpmyadmin and mysql database with single docker compose file
1. Create docker compose file for phpmyadmin . Name it as docker-compose.yml
2. Define two services db with image mysql:latest and phpmyadmin with image phpmyadmin:latest
3. Services db is exposed on port 3306 and phpmyadmin is exposed at port 8080.
4. Service phpmyadmin to be linked with db service. This directly provides access to the database to phpmyadmin.
links:
db
5. Run the docker image with the compose file
docker-compose -f docker-compose.yml up -d
Or
docker-compose up -d
6. Check docker logs
docker logs -f container-id
7. Access phpmyadmin with http://localhost:8080/.
8. Give username password
https://github.com/avetichamp/mysql-d...
Facebook : / aveti.tutorial.9
Chapters
0:00 Introduction
0:47 Phpmyadmin overview
3:35 Connect docker phpmyadmin with remote mysql database
7:31 Run Phpmyadmin and mysql with docker-compose file
Please like subscribe to this channel