-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathdocker-compose.qemu.yml
38 lines (36 loc) · 1.03 KB
/
docker-compose.qemu.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
version: "2"
services:
worker:
build: worker
device_cgroup_rules:
# https://www.kernel.org/doc/Documentation/admin-guide/devices.txt
# loopback devices
- "b 7:* rmw"
# metadata devices
- "b 9:* rmw"
# allow dynamic creation and access of qemu required misc chardev nodes
# this includes /dev/kvm, and /dev/net/tun
- "c 10:* rmw"
cap_add:
- NET_ADMIN # allow network setup
- SYS_ADMIN # privileged IOCTLs, such as used by mdadm
volumes:
- "core-storage:/data"
- "reports-storage:/reports"
- "qemu:/run/qemu/"
environment:
- UDEV=0
- WORKER_TYPE=qemu
- SCREEN_CAPTURE=true
- WORKER_PORT # default 80 and must match client config.js workers
- QEMU_ARCH=${QEMU_ARCH:-x86_64}
- QEMU_CPUS=${QEMU_CPUS}
- QEMU_MEMORY=${QEMU_MEMORY}
- QEMU_DEBUG=${QEMU_DEBUG}
- QEMU_INTERNAL_STORAGE=${QEMU_INTERNAL_STORAGE}
restart: 'no'
core:
volumes:
- "qemu:/run/qemu"
depends_on:
- worker