-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
73 lines (59 loc) · 2.01 KB
/
Copy pathdocker-compose.yml
File metadata and controls
73 lines (59 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
# ============================================================
# Canivete da Mata — Stack para Portainer
# ============================================================
# Como usar no Portainer:
# 1. Stacks > Add Stack > Web editor
# 2. Cole este conteúdo
# 3. Ajuste a variável IMAGE abaixo se necessário
# 4. Clique em "Deploy the stack"
#
# Para usar a imagem local (build no host):
# Altere a linha "image:" para: image: canivete-da-mata:latest
# E adicione o bloco "build:" abaixo.
# ============================================================
services:
canivete:
# Imagem pré-compilada do GitHub Container Registry (multi-arch)
# Suporta: linux/amd64, linux/arm64, linux/arm/v7, linux/riscv64
image: ghcr.io/facrf/canivete:latest
container_name: canivete-da-mata
restart: unless-stopped
ports:
- "7001:7001"
environment:
- TZ=America/Sao_Paulo
security_opt:
- no-new-privileges:true
cap_drop:
- ALL
read_only: true
tmpfs:
- /tmp:size=512M,mode=1777
# Limites de recursos recomendados (opcional)
deploy:
resources:
limits:
cpus: '1.0'
memory: 768M
reservations:
memory: 64M
# Health check para reinicialização automática em caso de falha
healthcheck:
test: ["CMD", "wget", "--quiet", "--tries=1", "--spider", "http://localhost:7001/healthz"]
interval: 30s
timeout: 5s
retries: 3
start_period: 10s
# Labels para integração com Traefik (descomente se usar Traefik como proxy)
# labels:
# - "traefik.enable=true"
# - "traefik.http.routers.canivete.rule=Host(`canivete.seu-dominio.com`)"
# - "traefik.http.routers.canivete.entrypoints=websecure"
# - "traefik.http.routers.canivete.tls.certresolver=letsencrypt"
# - "traefik.http.services.canivete.loadbalancer.server.port=7001"
# Rede opcional (remova se não usar uma rede externa)
# networks:
# - proxy
# networks:
# proxy:
# external: true