50 lines
886 B
YAML
50 lines
886 B
YAML
version: "3"
|
|
|
|
services:
|
|
argparse-builder:
|
|
build:
|
|
context: .
|
|
dockerfile: assets/Containerfile
|
|
container_name: argparse-builder
|
|
ports:
|
|
- "8080:8080"
|
|
restart: unless-stopped
|
|
|
|
# SELinux
|
|
security_opt:
|
|
- label=type:container_t
|
|
- no-new-privileges:true
|
|
|
|
# Security
|
|
read_only: true
|
|
cap_drop:
|
|
- ALL
|
|
|
|
# Resources
|
|
deploy:
|
|
resources:
|
|
limits:
|
|
cpus: "0.5"
|
|
memory: 128M
|
|
reservations:
|
|
cpus: "0.1"
|
|
memory: 32M
|
|
|
|
# Health
|
|
healthcheck:
|
|
test:
|
|
[
|
|
"CMD-SHELL",
|
|
"wget --no-verbose --tries=1 --spider http://localhost:8080/health || exit 1",
|
|
]
|
|
interval: 30s
|
|
timeout: 3s
|
|
retries: 3
|
|
start_period: 5s
|
|
|
|
# Logging
|
|
logging:
|
|
driver: journald
|
|
options:
|
|
tag: argparse-builder
|