[pve-devel] [PATCH RFC 1/3] Resources: add new flag 'start'

Dietmar Maurer dietmar at proxmox.com
Tue Nov 15 07:12:40 CET 2016


> > +	    description => "Flag for marking a resource as not able to " .
> > +		"start. This can be useful for Templates or also other " .
> > +		"resources which should be recovered on failure but not " .
> > +		"touched otherwise.",
> 
> Looking at patch 2 this not entirely true, we actively stop them as we 
> place them in request_stop state.
> So they get touched - if a VM is running an the start flag gets set to 
> false we stop it.
> The behaviour is OK for me, it just does not matches the description.

Yes. This is the behaviour I want. Sorry, I just copied the description from
your other patch.

But I wonder if we can remove that separate flag, and use an
additional state instead:

	state => {
	    description => "Resource state.",
	    type => 'string',
	    enum => ['enabled', 'enabled_stopped', 'disabled'],
	    optional => 1,
	    default => 'enabled',
	},




More information about the pve-devel mailing list