mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-29 05:09:46 +01:00
add: 部署文件
This commit is contained in:
parent
dd1b488d81
commit
26a48fdff5
5 changed files with 218 additions and 0 deletions
8
README-build.md
Normal file
8
README-build.md
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
## 构建镜像
|
||||
```shell
|
||||
docker build \
|
||||
--build-arg HTTP_PROXY=http://192.168.101.241:7890 \
|
||||
--build-arg HTTPS_PROXY=http://192.168.101.241:7890 \
|
||||
-f Dockerfile ./ \
|
||||
-t 192.168.101.99/yyn/192.168.101.99/yyn/esp32-server:1.0
|
||||
```
|
||||
54
compose-config/prod-244-docker-compose.yml
Normal file
54
compose-config/prod-244-docker-compose.yml
Normal file
|
|
@ -0,0 +1,54 @@
|
|||
version: '3.8'
|
||||
services:
|
||||
fish-speech:
|
||||
image: 192.168.101.99/yyn/fish-speech
|
||||
container_name: fishspeech
|
||||
restart: always
|
||||
privileged: true
|
||||
shm_size: '8gb' # 设置共享内存大小为 8GB,设置小了,服务无法启动
|
||||
network_mode: "bridge"
|
||||
volumes:
|
||||
- fish-speech-references:/opt/fish-speech/references
|
||||
- fish-speech-ckpt:/opt/fish-speech/checkpoints
|
||||
- fish-speech-models:/root/.cache/
|
||||
- fish-speech-models:/root/.cache/
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
device_ids: [ '1' ]
|
||||
capabilities: [ gpu ]
|
||||
environment:
|
||||
- GRADIO_SERVER_NAME=0.0.0.0
|
||||
- HOSTNAME=192.168.101.244
|
||||
command: python -m tools.api --listen 0.0.0.0:7861 --llama-checkpoint-path "checkpoints/fish-speech-1.4" --decoder-checkpoint-path "checkpoints/fish-speech-1.4/firefly-gan-vq-fsq-8x1024-21hz-generator.pth" --decoder-config-name firefly_gan_vq --compile
|
||||
ports:
|
||||
- "17861:7861"
|
||||
|
||||
|
||||
|
||||
volumes:
|
||||
fish-speech-references:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/fish-speech/references" # reference
|
||||
|
||||
fish-speech-ckpt:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/fish-speech/checkpoints" # ckpt
|
||||
|
||||
fish-speech-logs:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/var/logs/fishspeech/logs"
|
||||
|
||||
fish-speech-models:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/models" # 远程 hg/ms
|
||||
52
compose-config/prod-30-docker-compose.yml
Normal file
52
compose-config/prod-30-docker-compose.yml
Normal file
|
|
@ -0,0 +1,52 @@
|
|||
version: '3.8'
|
||||
services:
|
||||
fish-speech:
|
||||
image: 192.168.101.99/yyn/fish-speech
|
||||
container_name: fishspeech
|
||||
restart: always
|
||||
privileged: true
|
||||
shm_size: '8gb' # 设置共享内存大小为 8GB,设置小了,服务无法启动
|
||||
network_mode: "bridge"
|
||||
volumes:
|
||||
- fish-speech-references:/opt/fish-speech/references
|
||||
- fish-speech-ckpt:/opt/fish-speech/checkpoints
|
||||
- fish-speech-logs:/opt/fish-speech/logs
|
||||
- fish-speech-models:/root/.cache/
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
device_ids: [ '1' ]
|
||||
capabilities: [ gpu ]
|
||||
environment:
|
||||
- GRADIO_SERVER_NAME=0.0.0.0
|
||||
- HOSTNAME=192.168.61.30
|
||||
command: python -m tools.api --listen 0.0.0.0:7861 --llama-checkpoint-path "checkpoints/fish-speech-1.4" --decoder-checkpoint-path "checkpoints/fish-speech-1.4/firefly-gan-vq-fsq-8x1024-21hz-generator.pth" --decoder-config-name firefly_gan_vq --compile
|
||||
ports:
|
||||
- "17861:7861"
|
||||
|
||||
volumes:
|
||||
fish-speech-references:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/fish-speech/references" # reference
|
||||
|
||||
fish-speech-ckpt:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/fish-speech/checkpoints" # ckpt
|
||||
|
||||
fish-speech-logs:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/var/logs/fishspeech/logs"
|
||||
|
||||
fish-speech-models:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/models" # 远程 hg/ms
|
||||
78
compose-config/prod-31-docker-compose.yml
Normal file
78
compose-config/prod-31-docker-compose.yml
Normal file
|
|
@ -0,0 +1,78 @@
|
|||
version: '3.8'
|
||||
services:
|
||||
fish-speech-1:
|
||||
image: 192.168.101.99/yyn/fish-speech
|
||||
container_name: fishspeech-1
|
||||
restart: always
|
||||
privileged: true
|
||||
shm_size: '8gb' # 设置共享内存大小为 8GB,设置小了,服务无法启动
|
||||
network_mode: "bridge"
|
||||
volumes:
|
||||
- /data/share/tts-data/fish-speech/references:/opt/fish-speech/references
|
||||
- /data/share/tts-data/fish-speech/logs:/opt/fish-speech/logs
|
||||
- /data/share/tts-models/fish-speech/checkpoints:/opt/fish-speech/checkpoints
|
||||
- /data/share/models/cache:/root/.cache/
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
device_ids: ['1']
|
||||
capabilities: [gpu]
|
||||
environment:
|
||||
- GRADIO_SERVER_NAME=0.0.0.0
|
||||
command: python -m tools.api --listen 0.0.0.0:7861 --llama-checkpoint-path "checkpoints/fish-speech-1.4" --decoder-checkpoint-path "checkpoints/fish-speech-1.4/firefly-gan-vq-fsq-8x1024-21hz-generator.pth" --decoder-config-name firefly_gan_vq --compile
|
||||
ports:
|
||||
- "17861:7861"
|
||||
|
||||
fish-speech-2:
|
||||
image: yyn/fish-speech
|
||||
container_name: fishspeech-2
|
||||
restart: always
|
||||
privileged: true
|
||||
shm_size: '8gb' # 设置共享内存大小为 8GB,设置小了,服务无法启动
|
||||
network_mode: "bridge"
|
||||
volumes:
|
||||
- fish-speech-references:/opt/fish-speech/references
|
||||
- fish-speech-ckpt:/opt/fish-speech/checkpoints
|
||||
- fish-speech-models:/root/.cache/
|
||||
- fish-speech-models:/root/.cache/
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
device_ids: ['2']
|
||||
capabilities: [gpu]
|
||||
environment:
|
||||
- GRADIO_SERVER_NAME=0.0.0.0
|
||||
- HOSTNAME=192.168.61.31
|
||||
command: python -m tools.api --listen 0.0.0.0:7861 --llama-checkpoint-path "checkpoints/fish-speech-1.4" --decoder-checkpoint-path "checkpoints/fish-speech-1.4/firefly-gan-vq-fsq-8x1024-21hz-generator.pth" --decoder-config-name firefly_gan_vq --compile
|
||||
ports:
|
||||
- "17862:7861"
|
||||
|
||||
|
||||
volumes:
|
||||
fish-speech-references:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/fish-speech/references" # reference
|
||||
|
||||
fish-speech-ckpt:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/fish-speech/checkpoints" # ckpt
|
||||
|
||||
fish-speech-logs:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/var/logs/fishspeech/logs"
|
||||
|
||||
fish-speech-models:
|
||||
driver_opts:
|
||||
type: "nfs"
|
||||
o: "addr=192.168.101.244,nolock,soft,rw"
|
||||
device: ":/data/share/models" # 远程 hg/ms
|
||||
26
compose-config/test-243-docker-compose.yml
Normal file
26
compose-config/test-243-docker-compose.yml
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
version: '3.8'
|
||||
services:
|
||||
fish-speech:
|
||||
image: 192.168.101.99/yyn/192.168.101.99/yyn/esp32-server:1.0
|
||||
container_name: esp32-server
|
||||
restart: always
|
||||
privileged: true
|
||||
shm_size: '8gb' # 设置共享内存大小为 8GB,设置小了,服务无法启动
|
||||
network_mode: "bridge"
|
||||
volumes:
|
||||
- /appdata/share/tts-data/fish-speech/references:/opt/fish-speech/references
|
||||
- /appdata/share/tts-data/fish-speech/logs:/opt/fish-speech/logs
|
||||
- /appdata/share/tts-models/fish-speech/checkpoints:/opt/fish-speech/checkpoints
|
||||
- /appdata/share/models/cache:/root/.cache/
|
||||
deploy:
|
||||
resources:
|
||||
reservations:
|
||||
devices:
|
||||
- driver: nvidia
|
||||
capabilities: [gpu]
|
||||
device_ids: ['0','1']
|
||||
environment:
|
||||
- GRADIO_SERVER_NAME=0.0.0.0
|
||||
- HOSTNAME=192.168.101.243
|
||||
ports:
|
||||
- "18089:8080"
|
||||
Loading…
Reference in a new issue