Search code examples
vagrantvagrant-plugin

Disable vagrant plugin execution


Is there any way to disable a plugin execution?

For instance, we use vagrant-librarian-puppet-plugin and it gets automatically executed when there is a Puppetfile present. In some cases we want to avoid the execution even if the Puppetfile is present. Is possible to do that adding a configuration in the Vagrantfile?


Solution

  • You can't deactivate plugin; so you need to look into the specific settings of the given plugin.

    In the case of https://github.com/voxpupuli/vagrant-librarian-puppet you can't deactivate the plugin but you can tell it to look the Puppetfile into a directory where it will not be

    Vagrant.configure("2") do |config|
    
      config.librarian_puppet.puppetfile_dir = "directory_with_no_puppet_file"
    
    end
    

    Note: I have not tried it myself but looking the source it should be okay and will skip librarian provisioning