homelab/proxmox/services/nats.yml
Samantha Atkins f3017b9ab5 Add all swarm service definitions, CLAUDE.md, and gen-env.sh
Track all active Proxmox swarm stack YMLs, NATS config, Postgres
init SQL, and env generation script. Update .gitignore for homelab
project. Add CLAUDE.md for project context.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-29 03:51:11 -04:00

46 lines
875 B
YAML

version: '3.8'
# Deploy with:
# docker stack deploy -c nats.yml nats
#
# Runs on: pve-tools
# JetStream enabled for persistent messaging.
# Services connect to nats_nats:4222 via overlay, or host:4222 externally.
services:
nats:
image: nats:latest
command:
- -c=/etc/nats/nats.conf
ports:
- "4222:4222"
- "8080:8080"
- "8223:8222"
volumes:
- nats_data:/data
configs:
- source: nats_conf
target: /etc/nats/nats.conf
networks:
- overlay-net
deploy:
replicas: 1
placement:
constraints:
- node.hostname == pve-tools
restart_policy:
condition: on-failure
delay: 5s
max_attempts: 3
configs:
nats_conf:
file: ./nats.conf
volumes:
nats_data:
networks:
overlay-net:
external: true
name: ${OVERLAY_NETWORK:-homelab-net}