[Container-tools] vagrant-service-manager: overriding "flavor" guest capability has side effects

Lalatendu Mohanty lmohanty at redhat.com
Thu Mar 3 19:55:24 UTC 2016


On 03/04/2016 12:03 AM, Dusty Mabe wrote:
> PLEASE disregard last email - the subject of the message was wrong
>
> The vagrant-service-manager plugin is modifying the "flavor" guest capability [1].
>
> This has side effects on code (example at [2]) that assumes it is going to get back
> the that is returned from the actual flavor cap in vagrant core code [3].
>
> This is why hardy had such a hard time getting sshfs installed on his
> machine earlier today. The vagrant-sshfs plugin wasn't able to
> properly detect things and it didn't install sshfs for him.
>
> Opening up an issue on the plugin at [4]
>
> Dusty
>
> [1] https://github.com/projectatomic/vagrant-service-manager/blob/master/plugins/guests/redhat/cap/flavor.rb
> [2] https://github.com/dustymabe/vagrant-sshfs/blob/master/lib/vagrant-sshfs/cap/redhat/sshfs_client.rb#L26
> [3] https://github.com/mitchellh/vagrant/blob/master/plugins/guests/redhat/cap/flavor.rb
> [4] https://github.com/projectatomic/vagrant-service-manager/issues/91
>
> _______________________________________________
> Container-tools mailing list
> Container-tools at redhat.com
> https://www.redhat.com/mailman/listinfo/container-tools

This was unintended. I was unaware that if we change a method of a guest 
capability , it will effect other plugins.  As I have mentioned in the 
issue  we want to  introduce new guest capability named CDK and ADB 
similar to how fedora inherits from redhat (in Vagrant code base) then 
implement flavor method for CDK and ADB. This way we are not changing 
redhat capability's flavor method. But the current code seemed easy to 
implement.

Sorry for the inconvenience caused.

-Lala




More information about the Container-tools mailing list