feat(deployment): add secure Linux runtime (#17)
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
name: rendezvous-local
|
||||
|
||||
services:
|
||||
rendezvous:
|
||||
image: finalfactory/rendezvous:local
|
||||
build:
|
||||
context: ../..
|
||||
dockerfile: Dockerfile
|
||||
init: true
|
||||
user: "${RENDEZVOUS_UID:?set RENDEZVOUS_UID to a non-root host UID}:${RENDEZVOUS_GID:?set RENDEZVOUS_GID to its GID}"
|
||||
read_only: true
|
||||
tmpfs:
|
||||
- /tmp:rw,noexec,nosuid,nodev,size=16m,uid=${RENDEZVOUS_UID},gid=${RENDEZVOUS_GID},mode=0700
|
||||
cap_drop:
|
||||
- ALL
|
||||
security_opt:
|
||||
- no-new-privileges:true
|
||||
pids_limit: 128
|
||||
mem_limit: 512m
|
||||
cpus: 1.0
|
||||
ulimits:
|
||||
nofile:
|
||||
soft: 4096
|
||||
hard: 4096
|
||||
stop_grace_period: 40s
|
||||
restart: unless-stopped
|
||||
environment:
|
||||
ASPNETCORE_ENVIRONMENT: Production
|
||||
ASPNETCORE_HTTP_PORTS: "8080"
|
||||
volumes:
|
||||
- ./appsettings.Production.json:/app/appsettings.Production.json:ro
|
||||
- ./secrets/signing-key:/run/secrets/rendezvous-signing-key:ro
|
||||
ports:
|
||||
- "127.0.0.1:8080:8080/tcp"
|
||||
- "9050:9050/udp"
|
||||
Reference in New Issue
Block a user