Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IPv6 addresses #385

Closed
bitprophet opened this issue Aug 19, 2011 · 11 comments
Closed

IPv6 addresses #385

bitprophet opened this issue Aug 19, 2011 · 11 comments
Labels

Comments

@bitprophet
Copy link
Member

@bitprophet bitprophet commented Aug 19, 2011

Description

Currently it is not possible to specify IPv6 host address:

$ fab -H 2001:0DB8::1 taskname
[2001:0DB8::1] Executing task 'taskname'
Fatal error: Low level socket error connecting to host 2001: Invalid argument

Using square brackets http://serverfault.com/questions/205793/how-can-one-distinguish-the-difference-between-the-host-and-the-port-in-an-ipv6-u can help to separate address and port. And maybe we can make brackets optional by using more sophisticated regex patterns to distinguish IPv6 addresses from hostnames and IPv4 addresses.

What do you think?


Originally submitted by Max Arnold (LwarX) on 2011-07-11 at 01:18pm EDT

@ghost ghost assigned bitprophet Aug 19, 2011
@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Aug 19, 2011

Jeff Forcier (bitprophet) posted:


I am +1 on improving IPv6 support. What I'm unsure of is whether control over that is in our hands or if it's in the Paramiko level.

If you have time, take a gander at fabric/network.py::connect() and follow that as far as needed to figure out which eg os.socket calls are used. I don't remember offhand if we (or Paramiko) are using something that precludes use of IPv6 style addresses.

Hopefully it's just something dumb we're doing that is mangling it, but I suspect it may not be that easy.


on 2011-07-11 at 01:45pm EDT

@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Aug 19, 2011

Max Arnold (LwarX) posted:


I think Paramiko itself already supports IPv6 (both hostnames and raw addresses). SSHClient.connect() method accepts separate arguments for username/host/port, so there is no additional parsing required. I did a quick test with raw v6 address and it worked out just fine.

Fabric expects host specification in form username@host:port and fails to parse IPv6 notation because of semicolon. Hostnames with AAAA records are supported just fine (I was able to connect to v6-only machine by using DNS alias in /etc/hosts). What needs to be fixed is fabric/network.py::host_pattern, and related functions for host normalization/denormalization.


on 2011-07-11 at 03:11pm EDT

@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Aug 19, 2011

Jeff Forcier (bitprophet) posted:


I'm all ears for a better regex that is backwards compatible with how host strings behave now. Don't really have time to come up with it on my own at the moment :( especially as you're the first person to run into this specific problem so far -- it's not affecting a ton of people yet.


on 2011-07-11 at 04:37pm EDT

@max-arnold
Copy link

@max-arnold max-arnold commented Dec 2, 2011

Finally managed to do some work on this issue. Feature branch is here: https://github.com/max-arnold/fabric/tree/385-ipv6-hosts

@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Dec 2, 2011

Great, thanks -- let's move discussion over to the pull request.

@bitprophet bitprophet closed this Dec 2, 2011
@henrikno
Copy link

@henrikno henrikno commented Aug 2, 2012

What happened with this issue? I'm in need if IPv6 support.

@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Aug 3, 2012

Looks like Github failed to auto-link the related pull request, which is #491.

@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Aug 3, 2012

@Zerd If you have time to try and update Max's pull request patches so they apply to the current Fabric master branch, I can try to prioritize merging it. Thanks!

@max-arnold
Copy link

@max-arnold max-arnold commented Aug 5, 2012

I will be able to allocate some time to update the patch in a few days.

@bitprophet
Copy link
Member Author

@bitprophet bitprophet commented Aug 5, 2012

Thanks @max-arnold ! @Zerd, please follow #491 so we can keep discussion in one spot. Hopefully see you over there in a while, Max.

@max-arnold
Copy link

@max-arnold max-arnold commented Sep 2, 2012

@Zerd, could you please test the branch mentioned in #491?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants