-
Notifications
You must be signed in to change notification settings - Fork 16
/
nbs.yml
168 lines (158 loc) · 3.94 KB
/
nbs.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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
version: '3.3'
services:
################################################################################
# helper images
################################################################################
base:
image: ${NBS_PROJECT}_base:${VERSION:-latest}
environment:
- DHCLIENT_TIMEOUT=300
build:
context: ./base
args:
- VERSION=${VERSION:-latest}
###### connected in the virtual world to a gateway ########################
dhcp_client:
image: ${NBS_PROJECT}_dhcp_client:${VERSION:-latest}
build:
context: ./dhcp_client
args:
- VERSION=${VERSION:-latest}
privileged: true
cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
depends_on:
- base
###### connecting networks ################################################
gateway:
environment:
- UPSTREAM_NETWORK_NAME=internet
image: ${NBS_PROJECT}_gateway:${VERSION:-latest}
build:
context: ./gateway
args:
- VERSION=${VERSION:-latest}
hostname: private
privileged: true
cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
depends_on:
- base
- dhcp_client
networks:
private1:
private2:
################################################################################
# debugging and testing
################################################################################
rsyslog:
environment:
- KEEP_SERVICE_RUNNING=yes
tty: true
container_name: ${NBS_PROJECT}_rsyslog
hostname: rsyslog
image: ${NBS_PROJECT}_rsyslog:${VERSION:-latest}
build:
context: ./rsyslog
args:
- VERSION=${VERSION:-latest}
privileged: true
cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
security_opt:
- apparmor:docker-default
depends_on:
- upstream
expose:
- 514
- 514/udp
networks:
internet:
probe1:
environment:
- KEEP_SERVICE_RUNNING=yes
- DISPLAY=${DISPLAY}
tty: true
container_name: ${NBS_PROJECT}_probe1
hostname: probe1
image: ${NBS_PROJECT}_probe1:${VERSION:-latest}
build:
context: ./probe
args:
- VERSION=${VERSION:-latest}
privileged: true
cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
security_opt:
- apparmor:docker-default
depends_on:
- home0
volumes:
- /tmp/.X11-unix:/tmp/.X11-unix
networks:
home0:
# probe2:
# environment:
# - KEEP_SERVICE_RUNNING=yes
# - DISPLAY=${DISPLAY}
# tty: true
# container_name: ${NBS_PROJECT}_probe2
# hostname: probe2
# image: ${NBS_PROJECT}_probe2:${VERSION:-latest}
# build: ./probe
# privileged: true
# cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
# security_opt:
# - apparmor:docker-default
# depends_on:
# - telco0
# volumes:
# - /tmp/.X11-unix:/tmp/.X11-unix
# networks:
# telco0:
#
# probe3:
# environment:
# - KEEP_SERVICE_RUNNING=yes
# - DISPLAY=${DISPLAY}
# tty: true
# container_name: ${NBS_PROJECT}_probe3
# hostname: probe3
# image: ${NBS_PROJECT}_probe3:${VERSION:-latest}
# build: ./probe
# privileged: true
# cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
# security_opt:
# - apparmor:docker-default
# depends_on:
# - upstream
# volumes:
# - /tmp/.X11-unix:/tmp/.X11-unix
# networks:
# internet:
#
# probe4:
# environment:
# - KEEP_SERVICE_RUNNING=yes
# - DISPLAY=${DISPLAY}
# tty: true
# container_name: ${NBS_PROJECT}_probe4
# hostname: probe4
# image: ${NBS_PROJECT}_probe4:${VERSION:-latest}
# build: ./probe
# privileged: true
# cap_add: [ 'NET_ADMIN', 'NET_RAW' ]
# security_opt:
# - apparmor:docker-default
# depends_on:
# - upstream
# volumes:
# - /tmp/.X11-unix:/tmp/.X11-unix
# networks:
# upstream:
#
################################################################################
#
networks:
internet:
driver: macvlan
private1:
driver: macvlan
private2:
driver: macvlan