title: Commit a mysql docker image does not embed a new database
body: <p>If I create a database in a mysql container and commit it as a new image. The new image does not persit the database. Here is the scenario </p>
  
  <pre><code>docker run --name some-mysql -e MYSQL_ROOT_PASSWORD=my-secret-pw -d mysql
  docker exec -it some-mysql bash
  root@e756b3aa719b:/# mysql -uroot -pmy-secret-pw 
  
  mysql&gt; show databases;
  +--------------------+
  | Database           |
  +--------------------+
  | information_schema |
  | mysql              |
  | performance_schema |
  | sys                |
  +--------------------+
  4 rows in set (0.00 sec)
  
  mysql&gt; create database michael;
  
  mysql&gt; show databases;         
  +--------------------+
  | Database           |
  +--------------------+
  | information_schema |
  | michael            |
  | mysql              |
  | performance_schema |
  | sys                |
  +--------------------+
  5 rows in set (0.00 sec)
  
  mysql&gt; exit
  Bye
  root@e756b3aa719b:/# exit
  exit
  </code></pre>
  
  <p>Then I commit this container as an image </p>
  
  <pre><code>docker commit 486932c6d7e7 bdd/myproj:1.0
  </code></pre>
  
  <p>If I create a container from this image the database is not here </p>
  
  <pre><code>docker run --name newbdd -e  MYSQL_ROOT_PASSWORD=my-secret-pw -d mybdd/myproj:1.0
  docker exec -it newbdd bash
  root@004f86506ebf:/# mysql -uroot -pmy-secret-pw
  mysql&gt; show databases;
  +--------------------+
  | Database           |
  +--------------------+
  | information_schema |
  | mysql              |
  | performance_schema |
  | sys                |
  +--------------------+
  4 rows in set (0.01 sec)
  </code></pre>
  
  <p>What's really weird is that the mysql client kept the history of the command "create database michael" but the server does not keep the database michael.</p>
  
  <p>I don't understand why.</p>