-
Notifications
You must be signed in to change notification settings - Fork 6
/
ignition.json
45 lines (45 loc) · 2.53 KB
/
ignition.json
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
{
"ignition": {
"config": {},
"timeouts": {},
"version": "2.1.0"
},
"networkd": {},
"passwd": {},
"storage": {},
"systemd": {
"units": [
{
"dropins": [
{
"contents": "[Service]\nEnvironment=\"ETCD_NAME=av1\"\nEnvironment=\"ETCD_ADVERTISE_CLIENT_URLS=http://127.0.0.1:2379\"\nEnvironment=\"ETCD_INITIAL_ADVERTISE_PEER_URLS=http://127.0.0.1:2380\"\nEnvironment=\"ETCD_LISTEN_CLIENT_URLS=http://127.0.0.1:2379,http://172.17.0.1:2379\"\nEnvironment=\"ETCD_LISTEN_PEER_URLS=http://127.0.0.1:2380\"\nEnvironment=\"ETCD_INITIAL_CLUSTER=av1=http://127.0.0.1:2380\"\n",
"name": "conf1.conf"
}
],
"enabled": true,
"name": "etcd-member.service"
},
{
"mask": true,
"name": "locksmithd.service"
},
{
"mask": true,
"name": "update-engine.service"
},
{
"enabled": true,
"name": "docker.service"
},
{
"enabled": true,
"name": "systemd-networkd-wait-online.service"
},
{
"contents": "[Unit]\nDescription=NGINX RTMP Server\nWants=docker.service\nAfter=docker.service\n\n# Wait for network to become ready\nWants=systemd-networkd-wait-online.service\nAfter=systemd-networkd-wait-online.service\n\n[Service]\n# Set COREOS_PUBLIC_IPV4\nEnvironmentFile=/etc/environment\n\n# Allow time for Docker to download image\nTimeoutStartSec=0\n\n# Restart on failure\nRestartSec=10\nRestart=on-failure\n\n# Remove old containers if required\nExecStartPre=-/usr/bin/docker kill nginx-rtmp\nExecStartPre=-/usr/bin/docker rm nginx-rtmp\n\n# Pull image first if needed\nExecStartPre=/usr/bin/docker pull awakening/awakening-nginx-rtmp:2019-04-28\n\n# Setup initial configuration\nExecStartPre=/usr/bin/etcdctl set /live/secret ${publish_secret}\nExecStartPre=/usr/bin/etcdctl set /live/encodings/1 145:48:416x234\nExecStartPre=/usr/bin/etcdctl set /live/encodings/2 365:48:640x360\nExecStartPre=/usr/bin/etcdctl set /live/encodings/3 730:128:768x432\nExecStartPre=/usr/bin/etcdctl set /live/encodings/4 1100:128:768x432\nExecStartPre=/usr/bin/etcdctl set /live/encodings/5 2000:128:1080x720\n\n# Run bound to our IPv4 address, set DNS to Google Public DNS\nExecStart=/usr/bin/docker run --name nginx-rtmp --add-host=\"etcd:172.17.0.1\" -e ETCD_URL=http://etcd:2379 -p 80:80 -p 1935:1935 --dns 8.8.8.8 --dns 8.8.4.4 awakening/awakening-nginx-rtmp:2019-04-28\n\nExecStop=/usr/bin/docker stop nginx-rtmp\n",
"enabled": true,
"name": "nginx-rtmp.service"
}
]
}
}