fix docker volumes

This commit is contained in:
Zhang Minghan 2023-12-25 14:50:29 +08:00
parent 56f0994451
commit 34eb87bab8
5 changed files with 8 additions and 3 deletions

View File

@ -29,3 +29,7 @@ chat.exe
reverse reverse
access.json access.json
access/*.json access/*.json
db
cache
config

1
.gitignore vendored
View File

@ -22,3 +22,4 @@ access/*.json
db db
redis redis
config

View File

@ -112,7 +112,7 @@
``` ```
## 🔨 配置 | Config ## 🔨 配置 | Config
~/**config.yaml** ~/config/**config.yaml**
```yaml ```yaml
mysql: mysql:
db: chatnio db: chatnio

View File

@ -50,7 +50,7 @@ services:
REDIS_DB: 0 REDIS_DB: 0
SERVE_STATIC: "true" SERVE_STATIC: "true"
volumes: volumes:
- ./config.yaml:/config.yaml - ./config:/config
networks: networks:
- chatnio-network - chatnio-network

View File

@ -8,7 +8,7 @@ import (
"strings" "strings"
) )
var configFile = "config.yaml" var configFile = "config/config.yaml"
var configExampleFile = "config.example.yaml" var configExampleFile = "config.example.yaml"
func ReadConf() { func ReadConf() {