Open oleksandr-shalbanov-fntext opened 1 year ago
Hey @oleksandr-shalbanov-fntext,
thanks for reporting. Unfortunately, this is indeed a bug due to a missing passwordless sudo
configuration with your already mentioned and provided fix. This is covered in #2 and will be fixed in upcoming releases.
Sorry for that.
Cheers, gyptazy
Also I've noticed there is problems with vmware agent: ==> database: Waiting for HGFS to become available... And it never ends.....
Hello, is there any update on when this will be fixed? It looks like this has been open for about a year. Is there any workaround that can be done in the Vagrantfile before it attempts to change the hostname and hits the error?
Hey @twhalsema,
unfortunately not before. The only way is to wait until the error occurs, afterwards you can still login to the box with vagrant ssh
and use the box as usual and/or adjust the missing sudo config to avoid this behavior.
@gyptazy Thanks for the quick reply. I was able to script out what I needed with this workaround. I removed the hostname setting from the Vagrantfile. Then did this:
vagrant up <servername>
vagrant ssh <servername> -c "echo 'vagrant' | sudo -S sleep 1 && sudo sh -c \"echo 'vagrant ALL=(ALL) NOPASSWD:ALL' > /etc/sudoers.d/vagrant\" && sudo -S hostnamectl set-hostname <desired-hostname>"
Happy to hear :) enjoy!
During vagrant up getting following error:
Vagrant file:
Solution: after starting vm do vagrant ssh and run following: