This file contains data base schema .
instruction to create image of give name.
shell script to run required command.
docker build -t my_mysql .
- build : to build an image
- -t : option to provide tagname
- . : path(current directory)
Note: Make sure you are in same directory where dockerfile is placed.
docker run -it -d -p 3445:4000 my_mysql
docker ps
Note: Collect the container id of my_mysql for further use.
docker exec -it [Container_id] bash
# service mysql start
# mysql
mysql> use pucsdStudents
mysql> select * from studentData
=============================
docker-compose up -d
docker-compose down