Skip to content

Commit 11409fc

Browse files
feat: MySQL 容器时间与宿主机同步 (#72)
1 parent 295faa2 commit 11409fc

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

apps/mysql/versions/5.7.39/docker-compose.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ services:
1515
- ./data/:/var/lib/mysql
1616
- ./conf/my.cnf:/etc/mysql/my.cnf
1717
- ./log:/var/log/mysql
18+
- /etc/timezone:/etc/timezone:ro
19+
- /etc/localtime:/etc/localtime:ro
1820
command:
1921
--character-set-server=utf8mb4
2022
--collation-server=utf8mb4_general_ci

apps/mysql/versions/8.0.30/docker-compose.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ services:
1515
- ./data/:/var/lib/mysql
1616
- ./conf/my.cnf:/etc/my.cnf
1717
- ./log:/var/log/mysql
18+
- /etc/timezone:/etc/timezone:ro
19+
- /etc/localtime:/etc/localtime:ro
1820
labels:
1921
createdBy: "Apps"
2022
command:

0 commit comments

Comments
 (0)