-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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 destroy should remove client and node from chef server #336
Comments
I agree, this needs to be a feature in Vagrant. Marked as a feature, no milestone yet. |
In the meantime, add to the docs:
|
something like so? https://gist.github.com/1010660 |
Nice one skippy |
Skippy, thanks for that. I plan on implementing something like that into Vagrant as a full on feature. I'll use that as inspiration. |
Hello all, I've been thinking and working on this and I've ran into quite a few user-experience issues.
I do believe this is an important feature, but the complexity is rather high. Continuing with the plugin approach for users who need this may be the best approach. I'd like feedback. Thoughts? |
With #3, ask the user for his credentials (username & private key file) on the chef-server. |
I've decided to actually leave this up to the user for now, due to a lack of good libraries for Chef. |
Just commenting on the original issue (as I just had it and decided to solve it like this) I don't think extra features in vagrant are necessary with the following configuration: client_key_path = "/certificates" config.vm.define :some_node do |node_config| (Assuming you have a .gitignored writable certificates directory local to your Vagrantfile) This way, the first time you generate, it will register under a different node name (than the traditional published vagrant-distribution.vagrantup.com image node name), and store the cert in a shared folder, which next time you down/up it, will have access to its certificate. I would suggest being able to passthrough the client.pem as well as the validation.pem from host to guest as a way to solve it otherwise. |
When you use vagrant with Chef the first run of chef-client will register a new client and node with the chef server. When you issue a vagrant destroy command it does not delete the chef client and node. As a result developers find themselves continually bumping into the error "409: conflict, client already exists" every time they destroy a vagrant instance and this leads to wasted time. A great enhancement to vagrant would be to add some code to the destroy command would be the removal of the corresponding client and node from the chef server - this would allow people to repeatedly up/destroy images without the need for manual interaction each time.
The text was updated successfully, but these errors were encountered: