-
Notifications
You must be signed in to change notification settings - Fork 102
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
NoMethodError in run_instance #234
Comments
So this failed here:
This means that the image specified could probably not be found. Can I have your |
Vagrant.configure("2") do |config| config.vm.provider :google do |google, override|
end end I've tried numerous things. Used glcoud to list image names. Even tried you default. |
I ran with similar Vagrantfile as @scottbrumley:
I both tried by specifying image_family and image but I got same error.
and finally
I verified my user has the needed permissions. Can you help on this? |
@scottbrumley Your Vagrantfile looks correct, I have been able to launch a machine with it. @fabiomarinetti Perhaps the permissions are locked down on the organisation level somehow? You should be able to verify whether it's vagrant or something with your service account by making a direct call to the api like so:
|
Same here.
Update: It was because I used wrong service account for the project. |
@BirkhoffLee Can you tell me which permissions you were lacking? Perhaps we can add better error messages here. |
I had two projects A and B, I specified to use project B in this plugin but I used project A’s service account credentials in the config. |
I experienced this "NoMethodError in run_instance" issue and fixed it by adding "compute admin" on my service account. By the way, this is just my test environment so use a subset of this role on prod. Initially I was having this error when accessing the API. I agree that there should be a more descriptive error message on permission issue.
|
Just hit this: I mistyped the project name. Better error tracking would be helpful - or even a generic error to point the user in the right direction of checking SA permissions. |
* quickstart example config was missing required `image_project_id` to work at all (see mitchellh#234, mitchellh#228), * update the GCP setup instructions to their current web UI as of now, * reorganize initial setup sections for readability, * change headings a bit for consistency, * fix minor typos, replace http links with https etc.
* quickstart example config was missing required `image_project_id` to work at all (see mitchellh#234, mitchellh#228), * update the GCP setup instructions to their current web UI as of now, * update images versions to the current and available ones, * reorganize initial setup sections for readability, * change headings a bit for consistency, * fix minor typos, replace http links with https etc.
i think this's a vagrant issue because when i run direct call to API is working , however from vagrant hitting this error.
Just hitting this : ==> gcp: -- Accelerators: [] |
Kind of at my wits end here. No matter what I do I get this message.
/home/someuser/.vagrant.d/gems/2.4.9/gems/vagrant-google-2.5.0/lib/vagrant-google/action/run_instance.rb:108:in
call': undefined method
self_link' for nil:NilClass (NoMethodError)The text was updated successfully, but these errors were encountered: