Docker config

This commit is contained in:
ChKendel
2025-12-28 10:27:37 +01:00
parent f37c7ed81b
commit 8631ac7c53
3 changed files with 82 additions and 0 deletions

47
docker-compose.yml Normal file
View File

@@ -0,0 +1,47 @@
version: "3.3"
services:
appvideoserver:
build:
context: .
dockerfile: Dockerfile.appvideoserver
image: appvideoserver:latest
container_name: AppRobotVideo
working_dir: /usr/src/app
# Mount your host folder into the container
volumes:
- .:/usr/src/app
ports:
- "8448:8443"
extra_hosts:
- "host.docker.internal:host-gateway"
depends_on:
- roboticsdriver
init: true
command: >
sh -c "
if [ -f package-lock.json ] || [ -f npm-shrinkwrap.json ]; then
npm ci || npm install
else
npm install
fi
&& npm start"
environment:
- NODE_ENV=production
- HOST_UID=${UID-1000}
- HOST_GID=${GID-1000}
- DEV0=/dev/video0
- DEV1=/dev/video2
- TARGET_SERVER=wss://host.docker.internal:2095
restart: unless-stopped
networks:
clouds:
ipv4_address: 172.20.0.12
default:
privileged: true
cap_add:
- SYS_ADMIN
security_opt:
- seccomp:unconfined