Sign inSign up

kmelkez/mysql_client

By kmelkez

•Updated over 11 years ago

MySQL client image. Useful to interact (dump/import) with a MySQL server.

Image
0

3.3K

kmelkez/mysql_client repository overview

⁠MySQL client

Very lightweight MySQL client image. I'm using it to interact with a MySQL Server. You have two simple options to interact with your database : dump (mysqldump with -d option) and import (mysql command line)

docker run --rm --name mysql_migration -e ACTION=dump -e FILE_PREFIX="mysql" -e LOCATION_DIR="/var/www/deploy/db" --link $MYSQL_CONTAINER_NAME:db --volumes-from $DATA_CONTAINER_NAME kmelkez/mysql_client

It's important to name your MySQL container alias db because i'm using it to get linked environment variables of the MySQL container. Here⁠ is the convention for inherited environment variables.

--

For linked MySQL container, I'm using the official MySQL repository⁠

Tag summary

Content type

Image

Digest

sha256:11f915894…

Size

-

Last updated

over 11 years ago

docker pull kmelkez/mysql_client