iac/modules/netboot_server/files/dhcp/dnsmasq_container.container

28 lines
681 B
Text
Raw Normal View History

2024-06-04 09:25:59 +00:00
[Unit]
Description = DHCP Container
Wants=image_downloader.service
After=image_downloader.service
Wants=network-online.target
After=network-online.target
Wants=dhcp_config_init.service
After=dhcp_config_init.service
[Container]
ContainerName = dnsmasq_container
Image = localhost/dnsmasq:latest
Volume = dhcp_config.volume:/etc/dnsmasq.d:z
Volume = dhcp_data.volume:/data:z
Volume = /dev/log:/dev/log
Network = host
AddCapability = CAP_NET_ADMIN,CAP_NET_RAW
[Service]
WorkingDirectory=/var/roothome/dhcp
ExecStartPre=/bin/bash /var/roothome/generate_dhcp_options.sh
ExecStartPre=/usr/bin/podman build -t dnsmasq:latest .
Restart=on-failure
[Install]
WantedBy=multi-user.target