4d064b9e33
Passa a responder tambem no subdominio em nexcore.api.br e no caminho equivalente na raiz do dominio (servido de verdade, com remocao do prefixo, para nao quebrar POST). O host atual em neuralsys.com.br continua roteado. O casamento do caminho usa regex ancorada em limite de segmento, senao /whatsapi capturaria tambem /whatsapicg. No whatsapp-api este arquivo estava defasado no repositorio (descrevia o servico antigo api_zdg); foi substituido pelo compose que roda em producao. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
42 lines
1.6 KiB
YAML
42 lines
1.6 KiB
YAML
services:
|
|
whatsapp-api-oficial:
|
|
build: .
|
|
image: whatsapp-api-oficial:latest
|
|
container_name: whatsapp-api-oficial
|
|
restart: unless-stopped
|
|
env_file:
|
|
- .env
|
|
volumes:
|
|
- api_zdg_oficial_data:/usr/src/app/data
|
|
expose:
|
|
- "3001"
|
|
networks:
|
|
- default
|
|
- whatsapp-sys-net
|
|
labels:
|
|
- traefik.enable=true
|
|
- traefik.http.routers.whatsapp-api-oficial.rule=Host(`apimsgoficial.neuralsys.com.br`) || Host(`whatsapi.nexcore.api.br`)
|
|
- traefik.http.routers.whatsapp-api-oficial.entrypoints=websecure
|
|
- traefik.http.routers.whatsapp-api-oficial.tls=true
|
|
- traefik.http.routers.whatsapp-api-oficial.tls.certresolver=letsencrypt
|
|
- traefik.http.services.whatsapp-api-oficial.loadbalancer.server.port=3001
|
|
- traefik.http.routers.whatsapp-api-oficial-path.rule=Host(`nexcore.api.br`) && PathRegexp(`^/whatsapi(/|$$)`)
|
|
- traefik.http.routers.whatsapp-api-oficial-path.priority=150
|
|
- traefik.http.routers.whatsapp-api-oficial-path.entrypoints=websecure
|
|
- traefik.http.routers.whatsapp-api-oficial-path.tls=true
|
|
- traefik.http.routers.whatsapp-api-oficial-path.tls.certresolver=letsencrypt
|
|
- traefik.http.middlewares.whatsapp-api-oficial-strip.stripprefix.prefixes=/whatsapi
|
|
- traefik.http.routers.whatsapp-api-oficial-path.middlewares=whatsapp-api-oficial-strip
|
|
- traefik.http.routers.whatsapp-api-oficial-path.service=whatsapp-api-oficial
|
|
|
|
volumes:
|
|
api_zdg_oficial_data:
|
|
external: true
|
|
name: api_zdg_oficial_data
|
|
|
|
networks:
|
|
default: {}
|
|
whatsapp-sys-net:
|
|
name: whatsapp-sys_default
|
|
external: true
|