Code Monkey home page Code Monkey logo

Comments (15)

welcome avatar welcome commented on June 11, 2024

Thanks for opening your first issue here! Be sure to follow the issue template and include your OS/Vagrant/VVV versions! Don't forget you can get support in the VVV slack at https://varyingvagrantvagrants.org/docs/en-US/slack/

VVV
Join the VVV Slack Workspace

from vvv.

DianaKoenraadt avatar DianaKoenraadt commented on June 11, 2024

Oh yeah, and vagrant halt gives me

$ vagrant halt
==> default: Running action triggers before halt ...
==> default: Running trigger: VVV Pre-Halt...
==> default: Trigger run failed
==> default: ☺scp: /tmp/vagrant-shell: Read-only file system

from vvv.

tomjn avatar tomjn commented on June 11, 2024

Microsoft Windows

This is the critical information

==> default: ☺scp: /tmp/vagrant-shell: Read-only file system

yup if it can't SSH in then all sorts of stuff will be broken by default, VVV doesn't have a chance to even run provisioners


I'm assuming that because you mentioned a customfile ( 😱 😬 ) that this isn't your first VVV install, but, I suspect this is the first time you've used the specific command prompt you used.

That's because this kind of message heavily implies that there is no SSH Agent present:

The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

echo; printf $SSH_AUTH_SOCK

Oddly enough the best documentation available for this problem is on the official github docs. Vagrant needs to SSH into the VM, but Windows doesn't support Linux sockets so instead it has code to let it use a simulator like Msysgit or cygwin. Installing git bash, git for windows, or any of the official git on windows installers sets this up automatically and most people don't even realise it's a thing or have to do anything. That's why git is listed in the required software for Windows users.

However, if you use an unsupported command prompt or a weird command prompt, or skipped all of that and never installed git and used a zip file, or only used git inside WSL, then no SSH Agent is available that vagrant knows how to use, and you get messages like this.

from vvv.

tomjn avatar tomjn commented on June 11, 2024

This doc is probably what you want:

https://docs.github.com/en/authentication/connecting-to-github-with-ssh/using-ssh-agent-forwarding#your-local-ssh-agent-must-be-running

Remember to use an elevated administrator prompt ( without it host file modification won't work for most people, and symlinks will be broken in folders )

GitHub Docs
To simplify deploying to a server, you can set up SSH agent forwarding to securely use local SSH keys.

from vvv.

tomjn avatar tomjn commented on June 11, 2024

Also note that if you had said yes to the customfile question it would have meant instantly closing the issue as wontfix, you cannot ask for help here if you use customfile, it is forbidden. customfile == forfeit all support.

from vvv.

DianaKoenraadt avatar DianaKoenraadt commented on June 11, 2024

Can you explain why it worked before I created a Customfile and now after I delete the Customfile it does not work?
This is my first VVV installation (well, except two years ago). I have git installed.

from vvv.

tomjn avatar tomjn commented on June 11, 2024

Can you explain why it worked before I created a Customfile and now after I delete the Customfile it does not work? This is my first VVV installation (well, except two years ago). I have git installed.

This has nothing to do with your Customfile, it is coincidental

from vvv.

DianaKoenraadt avatar DianaKoenraadt commented on June 11, 2024

Sorry, I need a more thorough answer than "You don't have SSH" because an hour ago it worked.

from vvv.

DianaKoenraadt avatar DianaKoenraadt commented on June 11, 2024

I have the default setup. The changes I made:

  • renamed wordpress-one to wordpress-php74
  • renamed wordpress-two to wordpress-php80 and set php version to 8.0
  • added a Customfile to create a shared folder to wp-content/plugins/my-plugin
  • ran into read-only file system errors
  • Deleted the Customfile, emptied my trashcan and have been trying for the past hour to run vagrant halt, vagrant up --provision
  • Have tried to delete the Virtual Machine from VirtualBox and delete all data from disk, to have it recreate the VM

These are the only things I've been trying to do today, to set up a WordPress development environment.
Does that give any leads as to what's causing the hangup?

from vvv.

tomjn avatar tomjn commented on June 11, 2024

I do not know why the SSH agent was no longer present, but the github document I linked to should have contained commands that start it again resolving the issue.

As for why it happened, the cause could be any number of things that are unrelated to VVV, Windows updates, package managers, installers, launching a different type of command prompt by accident, or bad code in a customfile.

added a Customfile to create a shared folder to wp-content/plugins/my-plugin

This is a bad idea, overlapping shares can cause weirdness in VirtualBox. Try forcing it off in the VirtualBox admin, but as I said there are good reasons we do not offer support to people who use the customfile feature, that feature is explicitly there only for people who are comfortable and experienced with vagrant and ruby, people who could rebuild VVV from scratch if they had the time.

Sorry, I need a more thorough answer than "You don't have SSH" because an hour ago it worked.

I do not appreciate the hostile tone, please read our code of conduct. I'm not an employee, or paid support staff, I volunteer my time like others for an open source community project.

from vvv.

tomjn avatar tomjn commented on June 11, 2024

From the splash screen we can infer that the command prompt was likely gitbash, but that it was not started using an elevated administrator prompt:

Platform: mingw32 windows missingWinAdminPriv vagrant-goodhosts vagrant-vbgues
t monochrome-terminal shared_db_folder_disabled

monochrome-terminal also implies it's a wrapped cmd.exe rather than the newer Windows Terminal app

from vvv.

tomjn avatar tomjn commented on June 11, 2024

https://docs.github.com/en/authentication/connecting-to-github-with-ssh/working-with-ssh-key-passphrases?platform=windows#auto-launching-ssh-agent-on-git-for-windows

GitHub Docs
You can secure your SSH keys and configure an authentication agent so that you won't have to reenter your passphrase every time you use your SSH keys.

from vvv.

DianaKoenraadt avatar DianaKoenraadt commented on June 11, 2024

After multiple tries to reboot my laptop, delete the VM and running vagrant halt in various orders, VVV starts fine this morning.

The word "thorough" was misplaced, you wrote a lot already, it just didn't give me an actionable next step that applied to my setup (within my understanding of the situation). At some point you wrote "no SSH Agent present" and "or skipped all of that and never installed git". Given that it worked fine an hour ago and I spent quite some time downloading all the requirements, this made me conclude "no, that's surely not it, I have git installed and it worked, so I must have SSH Agent, it must be something else".

Given that this morning it worked, I'm sure you're right given the error, that the SSH Agent crashed or something.

I don't know VVV, only used it once two years ago. I mostly use any terminal that is at hand (git bash is great for me due to visual impairment, the colors help me see where I am).

from vvv.

tomjn avatar tomjn commented on June 11, 2024

Did you try the commands in the github doc I linked to?

from vvv.

DianaKoenraadt avatar DianaKoenraadt commented on June 11, 2024

Thanks. I used the following commands:
eval "$(ssh-agent -s)"
kill -9 <PID>

from vvv.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.