Skip to content

Commit 533c8fc

Browse files
committed
mysql create multiple database.
1 parent 0765184 commit 533c8fc

3 files changed

Lines changed: 10 additions & 0 deletions

File tree

docker-compose.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@ services:
194194
- MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD}
195195
volumes:
196196
- ${DATA_SAVE_PATH}/mysql:/var/lib/mysql
197+
- ./mysql/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
197198
ports:
198199
- "${MYSQL_PORT}:3306"
199200
networks:
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.sql
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
###
2+
### Copy createdb.sql.example to createdb.sql
3+
### then uncomment and set database name to create you need databases
4+
###
5+
6+
#CREATE DATABASE IF NOT EXISTS `dev_db_1` ;
7+
#CREATE DATABASE IF NOT EXISTS `dev_db_2` ;
8+
#CREATE DATABASE IF NOT EXISTS `dev_db_3` ;

0 commit comments

Comments
 (0)