lando / cli

The cli part of Lando
https://docs.lando.dev/cli
GNU General Public License v3.0
30 stars 33 forks source link

Lando requests using ipv6 failing #257

Closed ikphilip closed 6 months ago

ikphilip commented 7 months ago

Using v3.21.0-beta.1 on Linux. After installing for the first time I ran lando setup and received an array of errors on every plugin after the plugin installation matrix was generated. Here's an example of the message:

✖ Cannot Install! request to https://registry.npmjs.org/@lando%2facquia failed, reason: connect ENETUNREACH 2606:4700::6810:1922:443

This prevents lando from installing any plugins.

However I was able to resolve the issue on my local machine by disabling IPv6 support on my network device. After some investigation I discovered my ISP doesn't support IPv6. I used Network Manager to set my IPv6 configurations from 'Automatic' to 'Disabled' and re-ran lando setup. Now lando can retrieve and install the plugins successfully.

Should plugin retrieval have an IPv4 fallback in instances where the IPv6 address can't be resolved? Should lando or the underlying library know this by default? I don't have issues with other applications.

Here is output from lando setup --debug when lando fails to retrieve a plugin while building the installation matrix:

  lando compatibility results name=compose, link=https://docs.docker.com/compose/install/#install-compose-on-linux-systems, satisfied=true, wants=1.x.x || 2.x.x, dockerVersion=true, version=2.23.0, name=engine, link=https://docs.docker.com/engine/install/debian/#install-using-the-convenience-script, satisfied=true, wants=>=18 <25, dockerVersion=true, version=20.10.24 +0ms
  lando request to https://registry.npmjs.org/@lando%2facquia failed, reason: connect ENETUNREACH 2606:4700::6810:1f22:443  +152ms
  lando {"code":"ENETUNREACH","errno":"ENETUNREACH","syscall":"connect","address":"2606:4700::6810:1f22","port":443,"type":"system"}  +1ms
  lando emitting event post-install-plugins  +32ms
yolcuiskender commented 6 months ago

Can confirm that the #258 actually fixes the problem.

If you are on linux, you can temporary disable IPv6 with:

sudo sysctl -w net.ipv6.conf.all.disable_ipv6=1
sudo sysctl -w net.ipv6.conf.default.disable_ipv6=1

This change will not survive the reboot.

pirog commented 6 months ago

this should be resolved in the next release