Debian Codegraph @

upstream/debian-unstable/man5/systemd.nspawn.5

raw
1 '\" t
2 .TH "SYSTEMD\&.NSPAWN" "5" "" "systemd 261~rc3" "systemd.nspawn"
3 .\" -----------------------------------------------------------------
4 .\" * Define some portability stuff
5 .\" -----------------------------------------------------------------
6 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
7 .\" http://bugs.debian.org/507673
8 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
9 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
10 .ie \n(.g .ds Aq \(aq
11 .el .ds Aq '
12 .\" -----------------------------------------------------------------
13 .\" * set default formatting
14 .\" -----------------------------------------------------------------
15 .\" disable hyphenation
16 .nh
17 .\" disable justification (adjust text to left margin only)
18 .ad l
19 .\" -----------------------------------------------------------------
20 .\" * MAIN CONTENT STARTS HERE *
21 .\" -----------------------------------------------------------------
22 .SH "NAME"
23 systemd.nspawn \- Container settings
24 .SH "SYNOPSIS"
25 .PP
26 .RS 4
27 /etc/systemd/nspawn/\fImachine\fR\&.nspawn
28 .RE
29 .RS 4
30 /run/systemd/nspawn/\fImachine\fR\&.nspawn
31 .RE
32 .RS 4
33 /var/lib/machines/\fImachine\fR\&.nspawn
34 .RE
35 .SH "DESCRIPTION"
36 .PP
37 An nspawn container settings file (suffix
38 \&.nspawn) contains runtime configuration for a local container, and is used by
39 \fBsystemd-nspawn\fR(1)\&. Files of this type are named after the containers they define settings for\&. They are optional, and only required for containers whose execution environment shall differ from the defaults\&. Files of this type mostly contain settings that may also be set on the
40 \fBsystemd\-nspawn\fR
41 command line, and make it easier to persistently attach specific settings to specific containers\&. The syntax of these files is inspired by
42 \&.desktop
43 files, similarly to other configuration files supported by the systemd project\&. See
44 \fBsystemd.syntax\fR(7)
45 for an overview\&.
46 .SH "\&.NSPAWN FILE DISCOVERY"
47 .PP
48 Files are searched for by appending the
49 \&.nspawn
50 suffix to the machine name of the container, as specified with the
51 \fB\-\-machine=\fR
52 switch of
53 \fBsystemd\-nspawn\fR, or derived from the directory or image file name\&. This file is first searched for in
54 /etc/systemd/nspawn/
55 and
56 /run/systemd/nspawn/\&. If found there, the settings are read and all of them take full effect (but may still be overridden by corresponding command line arguments)\&. Otherwise, the file will then be searched for next to the image file or in the immediate parent of the root directory of the container\&. If the file is found there, only a subset of the settings will take effect however\&. All settings that possibly elevate privileges or grant additional access to resources of the host (such as files or directories) are ignored\&. To which options this applies is documented below\&.
57 .PP
58 Persistent settings files created and maintained by the administrator (and thus trusted) should be placed in
59 /etc/systemd/nspawn/, while automatically downloaded (and thus potentially untrusted) settings files are placed in
60 /var/lib/machines/
61 instead (next to the container images), where their security impact is limited\&. In order to add privileged settings to
62 \&.nspawn
63 files acquired from the image vendor, it is recommended to copy the settings files into
64 /etc/systemd/nspawn/
65 and edit them there, so that the privileged options become available\&. The precise algorithm for how the files are searched and interpreted may be configured with
66 \fBsystemd\-nspawn\fR\*(Aqs
67 \fB\-\-settings=\fR
68 switch, see
69 \fBsystemd-nspawn\fR(1)
70 for details\&.
71 .SH "[EXEC] SECTION OPTIONS"
72 .PP
73 Settings files may include an [Exec] section, which carries various execution parameters:
74 .PP
75 \fIBoot=\fR
76 .RS 4
77 Takes a boolean argument, which defaults to off\&. If enabled,
78 \fBsystemd\-nspawn\fR
79 will automatically search for an
80 init
81 executable and invoke it\&. In this case, the specified parameters using
82 \fIParameters=\fR
83 are passed as additional arguments to the
84 init
85 process\&. This setting corresponds to the
86 \fB\-\-boot\fR
87 switch on the
88 \fBsystemd\-nspawn\fR
89 command line\&. This option may not be combined with
90 \fIProcessTwo=yes\fR\&. This option is specified by default in the
91 systemd\-nspawn@\&.service
92 template unit\&.
93 .sp
94 Added in version 226\&.
95 .RE
96 .PP
97 \fIEphemeral=\fR
98 .RS 4
99 Takes a boolean argument, which defaults to off, If enabled, the container is run with a temporary snapshot of its file system that is removed immediately when the container terminates\&. This is equivalent to the
100 \fB\-\-ephemeral\fR
101 command line switch\&. See
102 \fBsystemd-nspawn\fR(1)
103 for details about the specific options supported\&.
104 .sp
105 Added in version 240\&.
106 .RE
107 .PP
108 \fIProcessTwo=\fR
109 .RS 4
110 Takes a boolean argument, which defaults to off\&. If enabled, the specified program is run as PID 2\&. A stub init process is run as PID 1\&. This setting corresponds to the
111 \fB\-\-as\-pid2\fR
112 switch on the
113 \fBsystemd\-nspawn\fR
114 command line\&. This option may not be combined with
115 \fIBoot=yes\fR\&.
116 .sp
117 Added in version 229\&.
118 .RE
119 .PP
120 \fIParameters=\fR
121 .RS 4
122 Takes a whitespace\-separated list of arguments\&. Single ("\*(Aq") and double (""") quotes may be used around arguments with whitespace\&. This is either a command line, beginning with the binary name to execute, or \(en if
123 \fIBoot=\fR
124 is enabled \(en the list of arguments to pass to the init process\&. This setting corresponds to the command line parameters passed on the
125 \fBsystemd\-nspawn\fR
126 command line\&.
127 .sp
128 Note:
129 \fBBoot=no\fR,
130 \fBParameters=a b "c c"\fR
131 is the same as
132 \fBsystemd\-nspawn a b "c c"\fR, and
133 \fBBoot=yes\fR,
134 \fBParameters=b \*(Aqc c\*(Aq\fR
135 is the same as
136 \fBsystemd\-nspawn \-\-boot b \*(Aqc c\*(Aq\fR\&.
137 .sp
138 Added in version 226\&.
139 .RE
140 .PP
141 \fIEnvironment=\fR
142 .RS 4
143 Takes an environment variable assignment consisting of key and value, separated by
144 "="\&. Sets an environment variable for the main process invoked in the container\&. This setting may be used multiple times to set multiple environment variables\&. It corresponds to the
145 \fB\-\-setenv=\fR
146 command line switch\&.
147 .sp
148 Added in version 226\&.
149 .RE
150 .PP
151 \fIUser=\fR
152 .RS 4
153 Takes a UNIX user name\&. Specifies the user name to invoke the main process of the container as\&. This user must be known in the container\*(Aqs user database\&. This corresponds to the
154 \fB\-\-user=\fR
155 command line switch\&.
156 .sp
157 Added in version 226\&.
158 .RE
159 .PP
160 \fIWorkingDirectory=\fR
161 .RS 4
162 Selects the working directory for the process invoked in the container\&. Expects an absolute path in the container\*(Aqs file system namespace\&. This corresponds to the
163 \fB\-\-chdir=\fR
164 command line switch\&.
165 .sp
166 Added in version 229\&.
167 .RE
168 .PP
169 \fIPivotRoot=\fR
170 .RS 4
171 Selects a directory to pivot to
172 /
173 inside the container when starting up\&. Takes a single path, or a pair of two paths separated by a colon\&. Both paths must be absolute, and are resolved in the container\*(Aqs file system namespace\&. This corresponds to the
174 \fB\-\-pivot\-root=\fR
175 command line switch\&.
176 .sp
177 Added in version 233\&.
178 .RE
179 .PP
180 \fICapability=\fR, \fIDropCapability=\fR
181 .RS 4
182 Takes a space\-separated list of Linux process capabilities (see
183 \fBcapabilities\fR(7)
184 for details)\&. The
185 \fICapability=\fR
186 setting specifies additional capabilities to pass on top of the default set of capabilities\&. The
187 \fIDropCapability=\fR
188 setting specifies capabilities to drop from the default set\&. These settings correspond to the
189 \fB\-\-capability=\fR
190 and
191 \fB\-\-drop\-capability=\fR
192 command line switches\&. Note that
193 \fICapability=\fR
194 is a privileged setting, and only takes effect in
195 \&.nspawn
196 files in
197 /etc/systemd/nspawn/
198 and
199 /run/system/nspawn/
200 (see above)\&. On the other hand,
201 \fIDropCapability=\fR
202 takes effect in all cases\&. If the special value
203 "all"
204 is passed, all capabilities are retained (or dropped)\&.
205 .sp
206 These settings change the bounding set of capabilities which also limits the ambient capabilities as given with the
207 \fIAmbientCapability=\fR\&.
208 .sp
209 Added in version 226\&.
210 .RE
211 .PP
212 \fIAmbientCapability=\fR
213 .RS 4
214 Takes a space\-separated list of Linux process capabilities (see
215 \fBcapabilities\fR(7)
216 for details)\&. The
217 \fIAmbientCapability=\fR
218 setting specifies capabilities which will be passed to the started program in the inheritable and ambient capability sets\&. This will grant these capabilities to this process\&. This setting correspond to the
219 \fB\-\-ambient\-capability=\fR
220 command line switch\&.
221 .sp
222 The value
223 "all"
224 is not supported for this setting\&.
225 .sp
226 The setting of
227 \fIAmbientCapability=\fR
228 must be covered by the bounding set settings which were established by
229 \fICapability=\fR
230 and
231 \fIDropCapability=\fR\&.
232 .sp
233 Note that
234 \fIAmbientCapability=\fR
235 is a privileged setting (see above)\&.
236 .sp
237 Added in version 248\&.
238 .RE
239 .PP
240 \fINoNewPrivileges=\fR
241 .RS 4
242 Takes a boolean argument that controls the
243 \fBPR_SET_NO_NEW_PRIVS\fR
244 flag for the container payload\&. This is equivalent to the
245 \fB\-\-no\-new\-privileges=\fR
246 command line switch\&. See
247 \fBsystemd-nspawn\fR(1)
248 for details\&.
249 .sp
250 Added in version 239\&.
251 .RE
252 .PP
253 \fIKillSignal=\fR
254 .RS 4
255 Specify the process signal to send to the container\*(Aqs PID 1 when nspawn itself receives SIGTERM, in order to trigger an orderly shutdown of the container\&. Defaults to SIGRTMIN+3 if
256 \fBBoot=\fR
257 is used (on systemd\-compatible init systems SIGRTMIN+3 triggers an orderly shutdown)\&. For a list of valid signals, see
258 \fBsignal\fR(7)\&.
259 .sp
260 Added in version 230\&.
261 .RE
262 .PP
263 \fIPersonality=\fR
264 .RS 4
265 Configures the kernel personality for the container\&. This is equivalent to the
266 \fB\-\-personality=\fR
267 switch\&.
268 .sp
269 Added in version 226\&.
270 .RE
271 .PP
272 \fIMachineID=\fR
273 .RS 4
274 Configures the 128\-bit machine ID (UUID) to pass to the container\&. This is equivalent to the
275 \fB\-\-uuid=\fR
276 command line switch\&. This option is privileged (see above)\&.
277 .sp
278 Added in version 226\&.
279 .RE
280 .PP
281 \fIPrivateUsers=\fR
282 .RS 4
283 Configures support for usernamespacing\&. This is equivalent to the
284 \fB\-\-private\-users=\fR
285 command line switch, and takes the same options\&. This option is privileged (see above)\&. This option is the default if the
286 systemd\-nspawn@\&.service
287 template unit file is used\&.
288 .sp
289 Added in version 230\&.
290 .RE
291 .PP
292 \fIPrivateUsersDelegate=\fR
293 .RS 4
294 Takes a non\-negative integer\&. Configures delegation of additional 64K UID/GID ranges into the container\*(Aqs user namespace for use by nested containers\&. When set to a value greater than zero, the
295 \fBsystemd-nsresourced.service\fR(8)
296 varlink socket will be bind\-mounted into the container so that processes inside the container can allocate further user namespaces from the delegated ranges\&. This is equivalent to the
297 \fB\-\-private\-users\-delegate=\fR
298 command line switch\&. Requires
299 \fIPrivateUsers=managed\fR\&. Defaults to 0\&. See
300 \fBsystemd-nspawn\fR(1)
301 for details\&.
302 .sp
303 Added in version 260\&.
304 .RE
305 .PP
306 \fINotifyReady=\fR
307 .RS 4
308 Configures support for notifications from the container\*(Aqs init process\&. This is equivalent to the
309 \fB\-\-notify\-ready=\fR
310 command line switch, and takes the same parameters\&. See
311 \fBsystemd-nspawn\fR(1)
312 for details about the specific options supported\&.
313 .sp
314 Added in version 231\&.
315 .RE
316 .PP
317 \fISystemCallFilter=\fR
318 .RS 4
319 Configures the system call filter applied to containers\&. This is equivalent to the
320 \fB\-\-system\-call\-filter=\fR
321 command line switch, and takes the same list parameter\&. See
322 \fBsystemd-nspawn\fR(1)
323 for details\&.
324 .sp
325 Added in version 235\&.
326 .RE
327 .PP
328 \fIRestrictAddressFamilies=\fR
329 .RS 4
330 Restricts the socket address families accessible to the container\&. This is equivalent to the
331 \fB\-\-restrict\-address\-families=\fR
332 command line switch, and takes the same list parameter\&. See
333 \fBsystemd-nspawn\fR(1)
334 for details\&.
335 .sp
336 Added in version 261\&.
337 .RE
338 .PP
339 \fILimitCPU=\fR, \fILimitFSIZE=\fR, \fILimitDATA=\fR, \fILimitSTACK=\fR, \fILimitCORE=\fR, \fILimitRSS=\fR, \fILimitNOFILE=\fR, \fILimitAS=\fR, \fILimitNPROC=\fR, \fILimitMEMLOCK=\fR, \fILimitLOCKS=\fR, \fILimitSIGPENDING=\fR, \fILimitMSGQUEUE=\fR, \fILimitNICE=\fR, \fILimitRTPRIO=\fR, \fILimitRTTIME=\fR
340 .RS 4
341 Configures various types of resource limits applied to containers\&. This is equivalent to the
342 \fB\-\-rlimit=\fR
343 command line switch, and takes the same arguments\&. See
344 \fBsystemd-nspawn\fR(1)
345 for details\&.
346 .sp
347 Added in version 239\&.
348 .RE
349 .PP
350 \fIOOMScoreAdjust=\fR
351 .RS 4
352 Configures the OOM score adjustment value\&. This is equivalent to the
353 \fB\-\-oom\-score\-adjust=\fR
354 command line switch, and takes the same argument\&. See
355 \fBsystemd-nspawn\fR(1)
356 for details\&.
357 .sp
358 Added in version 239\&.
359 .RE
360 .PP
361 \fICPUAffinity=\fR
362 .RS 4
363 Configures the CPU affinity\&. This is equivalent to the
364 \fB\-\-cpu\-affinity=\fR
365 command line switch, and takes the same argument\&. See
366 \fBsystemd-nspawn\fR(1)
367 for details\&.
368 .sp
369 Added in version 239\&.
370 .RE
371 .PP
372 \fIHostname=\fR
373 .RS 4
374 Configures the kernel hostname set for the container\&. This is equivalent to the
375 \fB\-\-hostname=\fR
376 command line switch, and takes the same argument\&. See
377 \fBsystemd-nspawn\fR(1)
378 for details\&.
379 .sp
380 Added in version 239\&.
381 .RE
382 .PP
383 \fIResolvConf=\fR
384 .RS 4
385 Configures how
386 /etc/resolv\&.conf
387 in the container shall be handled\&. This is equivalent to the
388 \fB\-\-resolv\-conf=\fR
389 command line switch, and takes the same argument\&. See
390 \fBsystemd-nspawn\fR(1)
391 for details\&.
392 .sp
393 Added in version 239\&.
394 .RE
395 .PP
396 \fITimezone=\fR
397 .RS 4
398 Configures how
399 /etc/localtime
400 in the container shall be handled\&. This is equivalent to the
401 \fB\-\-timezone=\fR
402 command line switch, and takes the same argument\&. See
403 \fBsystemd-nspawn\fR(1)
404 for details\&.
405 .sp
406 Added in version 239\&.
407 .RE
408 .PP
409 \fILinkJournal=\fR
410 .RS 4
411 Configures how to link host and container journal setups\&. This is equivalent to the
412 \fB\-\-link\-journal=\fR
413 command line switch, and takes the same parameter\&. See
414 \fBsystemd-nspawn\fR(1)
415 for details\&.
416 .sp
417 Added in version 239\&.
418 .RE
419 .PP
420 \fISuppressSync=\fR
421 .RS 4
422 Configures whether to suppress disk synchronization for the container payload\&. This is equivalent to the
423 \fB\-\-suppress\-sync=\fR
424 command line switch, and takes the same parameter\&. See
425 \fBsystemd-nspawn\fR(1)
426 for details\&.
427 .sp
428 Added in version 250\&.
429 .RE
430 .SH "[FILES] SECTION OPTIONS"
431 .PP
432 Settings files may include a [Files] section, which carries various parameters configuring the file system of the container:
433 .PP
434 \fIReadOnly=\fR
435 .RS 4
436 Takes a boolean argument, which defaults to off\&. If specified, the container will be run with a read\-only file system\&. This setting corresponds to the
437 \fB\-\-read\-only\fR
438 command line switch\&.
439 .sp
440 Added in version 226\&.
441 .RE
442 .PP
443 \fIVolatile=\fR
444 .RS 4
445 Takes a boolean argument, or the special value
446 "state"\&. This configures whether to run the container with volatile state and/or configuration\&. This option is equivalent to
447 \fB\-\-volatile=\fR, see
448 \fBsystemd-nspawn\fR(1)
449 for details about the specific options supported\&.
450 .sp
451 Added in version 226\&.
452 .RE
453 .PP
454 \fIBind=\fR, \fIBindReadOnly=\fR
455 .RS 4
456 Adds a bind mount from the host into the container\&. Takes a single path, a pair of two paths separated by a colon, or a triplet of two paths plus an option string separated by colons\&. This option may be used multiple times to configure multiple bind mounts\&. This option is equivalent to the command line switches
457 \fB\-\-bind=\fR
458 and
459 \fB\-\-bind\-ro=\fR, see
460 \fBsystemd-nspawn\fR(1)
461 for details about the specific options supported\&. This setting is privileged (see above)\&.
462 .sp
463 Added in version 226\&.
464 .RE
465 .PP
466 \fIBindUser=\fR
467 .RS 4
468 Binds a user from the host into the container\&. This option is equivalent to the command line switch
469 \fB\-\-bind\-user=\fR, see
470 \fBsystemd-nspawn\fR(1)
471 for details about the specific options supported\&. This setting is privileged (see above)\&.
472 .sp
473 Added in version 249\&.
474 .RE
475 .PP
476 \fIBindUserShell=\fR
477 .RS 4
478 When used with
479 \fIBindUser\fR, specifies the shell that is included in the user record of users bound from the host into the container\&. This option is equivalent to the command line switch
480 \fB\-\-bind\-user\-shell=\fR, see
481 \fBsystemd-nspawn\fR(1)
482 for details about the specific options supported\&. This setting is privileged (see above)\&.
483 .sp
484 Added in version 258\&.
485 .RE
486 .PP
487 \fITemporaryFileSystem=\fR
488 .RS 4
489 Adds a
490 "tmpfs"
491 mount to the container\&. Takes a path or a pair of path and option string, separated by a colon\&. This option may be used multiple times to configure multiple
492 "tmpfs"
493 mounts\&. This option is equivalent to the command line switch
494 \fB\-\-tmpfs=\fR, see
495 \fBsystemd-nspawn\fR(1)
496 for details about the specific options supported\&. This setting is privileged (see above)\&.
497 .sp
498 Added in version 226\&.
499 .RE
500 .PP
501 \fIInaccessible=\fR
502 .RS 4
503 Masks the specified file or directory in the container, by over\-mounting it with an empty file node of the same type with the most restrictive access mode\&. Takes a file system path as argument\&. This option may be used multiple times to mask multiple files or directories\&. This option is equivalent to the command line switch
504 \fB\-\-inaccessible=\fR, see
505 \fBsystemd-nspawn\fR(1)
506 for details about the specific options supported\&. This setting is privileged (see above)\&.
507 .sp
508 Added in version 242\&.
509 .RE
510 .PP
511 \fIOverlay=\fR, \fIOverlayReadOnly=\fR
512 .RS 4
513 Adds an overlay mount point\&. Takes a colon\-separated list of paths\&. This option may be used multiple times to configure multiple overlay mounts\&. This option is equivalent to the command line switches
514 \fB\-\-overlay=\fR
515 and
516 \fB\-\-overlay\-ro=\fR, see
517 \fBsystemd-nspawn\fR(1)
518 for details about the specific options supported\&. This setting is privileged (see above)\&.
519 .sp
520 Added in version 233\&.
521 .RE
522 .PP
523 \fIPrivateUsersOwnership=\fR
524 .RS 4
525 Configures whether the ownership of the files and directories in the container tree shall be adjusted to the UID/GID range used, if necessary and user namespacing is enabled\&. This is equivalent to the
526 \fB\-\-private\-users\-ownership=\fR
527 command line switch\&. This option is privileged (see above)\&.
528 .sp
529 Added in version 249\&.
530 .RE
531 .SH "[NETWORK] SECTION OPTIONS"
532 .PP
533 Settings files may include a [Network] section, which carries various parameters configuring the network connectivity of the container:
534 .PP
535 \fIPrivate=\fR
536 .RS 4
537 Takes a boolean argument, which defaults to off\&. If enabled, the container will run in its own network namespace and not share network interfaces and configuration with the host\&. This setting corresponds to the
538 \fB\-\-private\-network\fR
539 command line switch\&.
540 .sp
541 Added in version 226\&.
542 .RE
543 .PP
544 \fINamespacePath=\fR
545 .RS 4
546 Takes the path to a file representing a kernel network namespace that the container shall run in\&. The specified path should refer to a (possibly bind\-mounted) network namespace file, as exposed by the kernel below
547 /proc/$PID/ns/net\&. This makes the container enter the given network namespace\&. One of the typical use cases is to give a network namespace under
548 /run/netns
549 created by
550 \fBip-netns\fR(8), for example,
551 \fINamespacePath=/run/netns/foo\fR\&. Note that this option cannot be used together with other network\-related options, such as
552 \fIPrivate=\fR
553 or
554 \fIInterface=\fR\&. This option corresponds to the
555 \fB\-\-network\-namespace\-path\fR
556 command line switch\&.
557 .sp
558 Added in version 259\&.
559 .RE
560 .PP
561 \fIVirtualEthernet=\fR
562 .RS 4
563 Takes a boolean argument\&. Configures whether to create a virtual Ethernet connection ("veth") between host and the container\&. This setting implies
564 \fIPrivate=yes\fR\&. This setting corresponds to the
565 \fB\-\-network\-veth\fR
566 command line switch\&. This option is the default if the
567 systemd\-nspawn@\&.service
568 template unit file is used\&.
569 .sp
570 Added in version 226\&.
571 .RE
572 .PP
573 \fIVirtualEthernetExtra=\fR
574 .RS 4
575 Takes a colon\-separated pair of interface names\&. Configures an additional virtual Ethernet connection ("veth") between host and the container\&. The first specified name is the interface name on the host, the second the interface name in the container\&. The latter may be omitted in which case it is set to the same name as the host side interface\&. This setting implies
576 \fIPrivate=yes\fR\&. This setting corresponds to the
577 \fB\-\-network\-veth\-extra=\fR
578 command line switch, and may be used multiple times\&. It is independent of
579 \fIVirtualEthernet=\fR\&. Note that this option is unrelated to the
580 \fIBridge=\fR
581 setting below, and thus any connections created this way are not automatically added to any bridge device on the host side\&. This option is privileged (see above)\&.
582 .sp
583 Added in version 228\&.
584 .RE
585 .PP
586 \fIInterface=\fR
587 .RS 4
588 Takes a space\-separated list of interfaces to add to the container\&. The interface object is defined either by a single interface name, referencing the name on the host, or a colon\-separated pair of interfaces, in which case the first one references the name on the host, and the second one the name in the container\&. This option corresponds to the
589 \fB\-\-network\-interface=\fR
590 command line switch and implies
591 \fIPrivate=yes\fR\&. This option is privileged (see above)\&.
592 .sp
593 Added in version 226\&.
594 .RE
595 .PP
596 \fIMACVLAN=\fR, \fIIPVLAN=\fR
597 .RS 4
598 Takes a space\-separated list of interfaces to add MACLVAN or IPVLAN interfaces to, which are then added to the container\&. The interface object is defined either by a single interface name, referencing the name on the host, or a colon\-separated pair of interfaces, in which case the first one references the name on the host, and the second one the name in the container\&. These options correspond to the
599 \fB\-\-network\-macvlan=\fR
600 and
601 \fB\-\-network\-ipvlan=\fR
602 command line switches and imply
603 \fIPrivate=yes\fR\&. These options are privileged (see above)\&.
604 .sp
605 Added in version 226\&.
606 .RE
607 .PP
608 \fIBridge=\fR
609 .RS 4
610 Takes an interface name\&. This setting implies
611 \fIVirtualEthernet=yes\fR
612 and
613 \fIPrivate=yes\fR
614 and has the effect that the host side of the created virtual Ethernet link is connected to the specified bridge interface\&. This option corresponds to the
615 \fB\-\-network\-bridge=\fR
616 command line switch\&. This option is privileged (see above)\&.
617 .sp
618 Added in version 226\&.
619 .RE
620 .PP
621 \fIZone=\fR
622 .RS 4
623 Takes a network zone name\&. This setting implies
624 \fIVirtualEthernet=yes\fR
625 and
626 \fIPrivate=yes\fR
627 and has the effect that the host side of the created virtual Ethernet link is connected to an automatically managed bridge interface named after the passed argument, prefixed with
628 "vz\-"\&. This option corresponds to the
629 \fB\-\-network\-zone=\fR
630 command line switch\&. This option is privileged (see above)\&.
631 .sp
632 Added in version 230\&.
633 .RE
634 .PP
635 \fIPort=\fR
636 .RS 4
637 Exposes a TCP or UDP port of the container on the host\&. This option corresponds to the
638 \fB\-\-port=\fR
639 command line switch, see
640 \fBsystemd-nspawn\fR(1)
641 for the precise syntax of the argument this option takes\&. This option is privileged (see above)\&.
642 .sp
643 Added in version 226\&.
644 .RE
645 .SH "SEE ALSO"
646 .PP
647 \fBsystemd\fR(1), \fBsystemd-nspawn\fR(1), \fBsystemd.directives\fR(7)