java - Save tables in Docker container -
i need advice best practice, maybe. need start web application web server , database. how link web server database found out. have problem db.
if wanna save tables after server down (server containers start). know information of container reset after delete. know verbose folders(-v
flag) don't know mysql
save it's tables , other information , don't know idea.
so, tell me how correctly save created tables in container?
you can take @ tutorial:
https://github.com/tutumcloud/tutum-docker-mysql
basically, have mysql on machine , then, on /var/lib/mysql
, can start container:
docker run -d -p 3306:3306 -v /var/lib/mysql:/var/lib/mysql tutum/mysql
in case, i'm using tutum/mysql
image. mounting database file volume host container. when container goes down, still have data on machine.
Comments
Post a Comment