[systemd-devel] static IP inside container
arnaud.gaboury at gmail.com
Sun Feb 23 06:55:30 PST 2014
I set up a arch linux container on my arch box.
The container (dahlia) boots, works and connect fine.
Now I want to set up a static IP on the container, and I must admit I am
loosing my mind.
The overall set up :
on host :
dhcpcd at enp7s0.service - dhcpcd on enp7s0
Loaded: loaded (/usr/lib/systemd/system/dhcpcd at .service; enabled)
Active: active (running) since Sun 2014-02-23 14:44:07 CET; 53min ago
Process: 382 ExecStart=/usr/bin/dhcpcd -q -w %I (code=exited,
Main PID: 515 (dhcpcd)
CGroup: /system.slice/system-dhcpcd.slice/dhcpcd at enp7s0.service
└─515 /usr/bin/dhcpcd -q -w enp7s0
$ ip addr
inet 192.168.1.87/24 brd 192.168.1.255 scope global enp7s0
--> Shall I use a bridge on host ?
On guest :
I disabled dhcpcd at .service, then
I was thinking using this profile (named dahliaVM) with netctl :
Description='A basic static ethernet connection'
#Routes=('192.168.0.0/24 via 192.168.1.2')
the etc/systemd/system/netctl at dahliaVM.service is here with inside:
Description=A basic static ethernet connection
Unfortunately this setup do not work.
gab at dahlia ➤➤ ~ % systemctl status netctl at dahliaVM.service
netctl at dahliaVM.service - A basic static ethernet connection
Loaded: loaded (/etc/systemd/system/netctl at dahliaVM.service; static)
Active: inactive (dead)
Feb 23 14:46:51 dahlia systemd: Dependency failed for A basic static
Feb 23 15:23:13 dahlia systemd: Dependency failed for A basic static
Feb 23 15:26:28 dahlia systemd: Dependency failed for A basic static
I was thinking too using the new systemd-network facility, but it is too
new for me, and if the host is running systemd-git, the container is with
I would appreciate some help to set up a static Ip on the container
different from the host IP.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the systemd-devel