@@ -38,42 +38,41 @@ docker run -d --name gocron2-node \
38
38
> Multiple nodes with certs
39
39
40
40
``` bash
41
- # Create certs for main node
41
+ # Create certs for main node (we mount conf/ to out/, because certs will output to out/)
42
42
docker run --rm \
43
- -v /path/to/out :/gocron2/out \
43
+ -v /path/to/conf :/gocron2/out \
44
44
sstc/gocron2 ./init-cert.sh
45
45
46
46
# Create certs for worker nodes
47
47
docker run --rm \
48
- -v /path/to/out :/gocron2/out \
48
+ -v /path/to/conf :/gocron2/out \
49
49
sstc/gocron2 ./init-cert.sh 1.2.3.4
50
50
51
51
# Configure main node: add those to /path/to/conf/app.ini
52
52
# enable_tls = true
53
- # ca_file = /gocron2/out /Root_CA.crt
54
- # cert_file = /gocron2/out /127.0.0.1.crt
55
- # key_file = /gocron2/out /127.0.0.1.key
53
+ # ca_file = /gocron2/conf /Root_CA.crt
54
+ # cert_file = /gocron2/conf /127.0.0.1.crt
55
+ # key_file = /gocron2/conf /127.0.0.1.key
56
56
57
57
# Up main node
58
58
docker run -d --name gocron2 \
59
59
-v /path/to/conf:/gocron2/conf \
60
60
-v /path/to/log:/gocron2/log \
61
- -v /path/to/out:/gocron2/out \
62
61
-p 5920:5920 \
63
62
sstc/gocron2:server
64
63
65
- # Copy cert files in /path/to/out for the worker nodes
64
+ # Copy cert files in /path/to/conf for the worker nodes
66
65
67
66
# Up all worker nodes
68
67
docker run -d --name gocron2-node \
69
- -v /path/to/out :/gocron2/out \
68
+ -v /path/to/conf :/gocron2/conf \
70
69
-v /path/to/my-task-scripts:/app \
71
70
-p 5921:5921 \
72
71
sstc/gocron2 gocron2-node -allow-root \
73
72
-enable-tls \
74
- -ca-file /gocron2/out /Root_CA.crt \
75
- -cert-file /gocron2/out /1.2.3.4.crt \
76
- -key-file /gocron2/out /1.2.3.4.key
73
+ -ca-file /gocron2/conf /Root_CA.crt \
74
+ -cert-file /gocron2/conf /1.2.3.4.crt \
75
+ -key-file /gocron2/conf /1.2.3.4.key
77
76
78
77
# Open 127.0.0.1:5920 to install
79
78
```
0 commit comments