forked from selkies-project/docker-nvidia-glx-desktop
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
86 lines (86 loc) · 4.45 KB
/
docker-compose.yml
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
74
75
76
77
78
79
80
81
82
83
84
85
86
services:
xgl:
container_name: xgl
hostname: xgl
# Change tag `latest` to Ubuntu versions such as `24.04`, use a persistent tag such as `24.04-20210101010101` to persist a certain container version
image: ghcr.io/selkies-project/nvidia-glx-desktop:latest
ports:
- '8080:8080'
# Internal TURN server settings
# - '3478:3478'
# - '65534-65535:65534-65535'
# - '3478:3478/udp'
# - '65534-65535:65534-65535/udp'
stdin_open: true
tty: true
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
tmpfs:
- '/dev/shm:rw'
# volumes:
# - 'xgl-cache-vol:/cache'
# - 'xgl-root-vol:/home/ubuntu'
# Uncomment the below line to disable network isolation for WebRTC connectivity, display `:20` and `:21` should not be used in the host, may show an error if disallowed by the cluster
# network_mode: 'host'
environment:
- TZ=UTC
- DISPLAY_SIZEW=1920
- DISPLAY_SIZEH=1080
- DISPLAY_REFRESH=60
- DISPLAY_DPI=96
- DISPLAY_CDEPTH=24
# With driver versions lower than 550, change to `DP-0` or any other `DP-*` port for larger resolution support if NOT using datacenter GPUs
- VIDEO_PORT=DFP
# User password of container
- PASSWD=mypasswd
# Uncomment to enable KasmVNC instead of Selkies-GStreamer, `SELKIES_BASIC_AUTH_PASSWORD` is used for authentication with KasmVNC, defaulting to `PASSWD` if not provided
# Uses: `SELKIES_ENABLE_BASIC_AUTH`, `SELKIES_BASIC_AUTH_USER`, `SELKIES_BASIC_AUTH_PASSWORD`, `SELKIES_ENABLE_RESIZE`, `SELKIES_ENABLE_HTTPS`, `SELKIES_HTTPS_CERT`, `SELKIES_HTTPS_KEY`
# - KASMVNC_ENABLE=true
# Number of threads for encoding frames with KasmVNC, default value is all threads
# - name: KASMVNC_THREADS=0
###
# Selkies-GStreamer parameters, for additional configurations see `selkies-gstreamer --help`
###
# Change `SELKIES_ENCODER` to `x264enc`, `vp8enc`, or `vp9enc` if using software fallback without allocated GPUs or your GPU does not support `H.264 (AVCHD)` under the `NVENC - Encoding` section in https://developer.nvidia.com/video-encode-and-decode-gpu-support-matrix-new
- SELKIES_ENCODER=nvh264enc
- SELKIES_ENABLE_RESIZE=false
# Initial video bitrate in kilobits per second, may be changed later within web interface
- SELKIES_VIDEO_BITRATE=8000
# Initial frames per second, may be changed later within web interface
- SELKIES_FRAMERATE=60
# Initial audio bitrate in bits per second, may be changed later within web interface
- SELKIES_AUDIO_BITRATE=128000
# Uncomment if network conditions rapidly fluctuate
# - SELKIES_CONGESTION_CONTROL=true
# Enable basic authentication with the web interface
- SELKIES_ENABLE_BASIC_AUTH=true
# Defaults to `PASSWD` if unspecified
# - SELKIES_BASIC_AUTH_PASSWORD=mypasswd
# Enable HTTPS web interface from inside the container
- SELKIES_ENABLE_HTTPS=false
# Volume mount trusted HTTPS certificate to new path for no web browser warnings
# - SELKIES_HTTPS_CERT=/etc/ssl/certs/ssl-cert-snakeoil.pem
# - SELKIES_HTTPS_KEY=/etc/ssl/private/ssl-cert-snakeoil.key
###
# Uncomment and configure below to use a TURN server for improved network compatibility
###
# - SELKIES_TURN_HOST=turn.example.com
# - SELKIES_TURN_PORT=3478
# Change to `tcp` if the UDP protocol is throttled or blocked in your client network, or when the TURN server does not support UDP
# - SELKIES_TURN_PROTOCOL=udp
# You need a valid hostname and a certificate from authorities such as ZeroSSL or Let's Encrypt to enable this
# - SELKIES_TURN_TLS=false
# Internal TURN server settings, do not uncomment other TURN server settings below this when using an internal TURN server
# - TURN_MIN_PORT=65534
# - TURN_MAX_PORT=65535
# Provide only `SELKIES_TURN_SHARED_SECRET` for time-limited shared secret authentication or both `SELKIES_TURN_USERNAME` and `SELKIES_TURN_PASSWORD` for legacy long-term authentication, but do not provide both authentication methods at the same time
# - SELKIES_TURN_SHARED_SECRET=n0TaRealCoTURNAuthSecretThatIsSixtyFourLengthsLongPlaceholdPlace
# - SELKIES_TURN_USERNAME=username
# - SELKIES_TURN_PASSWORD=mypasswd
# TURN REST URI authentication, all TURN server settings above are ignored if enabled
# - 'SELKIES_TURN_REST_URI=http://localhost:8008'