Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
IPv6 Network states is incomplete #38672
Description of Issue/Question
I'm trying to deploy IPv6 Addresses to my minions, but following documentation, it doesn't work.
I have looked at states/modules in develop branch about networking and debian.IP but can't be able to find some usefull thinks for v6.
The output in
Steps to Reproduce Issue
(Include debug logs if possible and relevant.)
(Provided by running
We have exactly the same issue here with Salt 2017.7.3.
Is it really not possible to configure IPv6 with Salts? Any known workarounds?
And, no, even adding the netmask doesn`t help!
Also to note I found this issue related to debian networking that has a state included if you want to give that a go: #37942
@valentin2105 You said it "doesn't work" but I'm not sure you clearly indicated what that means. Is the problem simply that the netmask isn't making it's way to the configuration file when written, or are there other things that do not behave as expected?
If it's just the netmask, that probably shouldn't be too terrible to track down.
There is no IP in the generated output unlike in the yaml file.
If you said so, I still don't see it. However, I also had a very hard time trying to comprehend what I read so it's possible I'm still missing it.
Anyway... it's not just the IP address that is not being included. The netmask is also missed. This is happening because the debian_ip module and templates have no logic for how to handle the data you're trying to throw at it.
If you look at the sample I provided in the bug @Ch3LL mentioned, you'll see that ipaddrs/ipv6addrs (should be ipv6ipaddrs*) was never considered during testing. However, many configurations /were/ considered, and a few included IPv6. If you're only trying to assign one IPv6 address to the interface, then that bit of information has you covered.
If you actually need multiple addresses per interface, then that is something the debian_ip module does not support. You will need to add this support.
To add support for multiple addresses per interface, you'll want to look around _parse_settings_eth() _write_file_ifaces(), and build_interface() of debian_ip. Ultimately, the data structure you build will be parsed by templates/debian_ip/debian_eth.jinja.
I also noticed another snafu...
I'm having a similar issue with trying to configure a single IPv6 address on an interface. In this case, the interface is a "dummy" interface and already has an IPv4 address. The managed system is Ubuntu 18.04 and the salt version is salt 2018.3.2 (Oxygen).
The state I tried was:
That seemed to not put anything into the /etc/network/interfaces for the IPv6 stuff
I'm not sure if this is supported or if I'm just doing it wrong.
After digging into the source a bit, I'm realizing that there's no way to configure a loopback device via salt. I'm working on a PR that fixes this mistake and updates documentation.
When the PR is complete, a loopback interface will be configurable with: