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

Vagrant_ip on 'dhcp' results in error/no ip. #1070

Open
5 of 6 tasks
Xilonz opened this issue Feb 16, 2019 · 2 comments
Open
5 of 6 tasks

Vagrant_ip on 'dhcp' results in error/no ip. #1070

Xilonz opened this issue Feb 16, 2019 · 2 comments

Comments

@Xilonz
Copy link

Xilonz commented Feb 16, 2019


What is the current behavior?

hostname -I | cut -d ' ' -f 2 returns nothing.

What is the expected or desired behavior?

A better logging output and/or it actually working.

hostname -I | cut -d ' ' -f 1 returns its actual ip.

Why not use vm.provider.driver.read_guest_ip()['ip'] instead? I don't have VirtualBox (or any other than hyper-v), but the VirtualBox driver does have the same function.


Bug report

==> default: [vagrant-hostmanager:guests] Updating hosts file on active guest virtual machines...
c:/Users/steen/git/trellis-hyper-v-test/trellis/Vagrantfile:40:in `block (3 levels) in <top (required)>': undefined method `[]' for nil:NilClass (NoMethodError)

Please describe your local environment:

Ansible version: 2.5.1
OS: Windows 10, build 17763
Vagrant version: 2.2.3
VM: Hyper-V

Where did the bug happen? Development or remote servers?

Development

Is there a related Discourse thread or were any utilized (please link them)?

I've documented my experiences with hyper-v here

@swalkinshaw
Copy link
Member

I didn't even know about vm.provider.driver.read_guest_ip. That does seem better...

Although Trellis does technically support parallels and vmware. I searched Vagrant and read_guest_ip only appears in VB and HyperV. Not sure how much this matters though?

@swalkinshaw
Copy link
Member

@Xilonz are you still using Trellis + HyperV? Would be able to test a few variations on this if I provide them?

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

No branches or pull requests

2 participants