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

Add the guest's LAN IP to list of addresses in installer #291

Open
dshoreman opened this issue Oct 13, 2020 · 0 comments
Open

Add the guest's LAN IP to list of addresses in installer #291

dshoreman opened this issue Oct 13, 2020 · 0 comments
Labels
enhancement New feature or request hacktoberfest Ideal issue for Hacktoberfest

Comments

@dshoreman
Copy link
Owner

When installation completes, a success message is shown with a list of links Servidor can be accessed with.

Currently these are servidor.local and the public IP:

info "Servidor is listening at the following addresses:"
info " ${app_url}:8042/"
info " http://$(dig -4 +short myip.opendns.com @resolver1.opendns.com):8042/"

When running Vagrant without one of the hostmanager or hostsupdater plugins however, /etc/hosts isn't updated automatically and so servidor.local won't work. In that case, it's also likely the public IP will not be usable due to lack of port forwarding.

By adding the machine's local IP before the public IP, all our bases are covered.


Note that the Vagrant VM has 3 network adapters. The one we want is likely to be the last one, but that might not be a certainty. Physical servers will vary even more, so it's probably best to add the local IP inside an if is_vagrant block.

Output from ip addr list in my Vagrant install:

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 02:95:95:10:ca:f7 brd ff:ff:ff:ff:ff:ff
    inet 10.0.2.15/24 brd 10.0.2.255 scope global dynamic enp0s3
       valid_lft 82462sec preferred_lft 82462sec
    inet6 fe80::95:95ff:fe10:caf7/64 scope link
       valid_lft forever preferred_lft forever
3: enp0s8: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 08:00:27:4b:7b:6a brd ff:ff:ff:ff:ff:ff
    inet 192.168.10.100/24 brd 192.168.10.255 scope global enp0s8
       valid_lft forever preferred_lft forever
    inet6 fe80::a00:27ff:fe4b:7b6a/64 scope link
       valid_lft forever preferred_lft forever
@dshoreman dshoreman added enhancement New feature or request hacktoberfest Ideal issue for Hacktoberfest labels Oct 13, 2020
@dshoreman dshoreman added this to To do in Installer and Workflow via automation Oct 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request hacktoberfest Ideal issue for Hacktoberfest
Projects
Development

No branches or pull requests

1 participant