func (p Profile) ValidateConfigDevices() error {
	for _, val := range p.Devices {
		goodDevs := set.NewStrings("unix-char", "unix-block", "gpu", "usb")
		if devType, ok := val["type"]; ok {
			if !goodDevs.Contains(devType) {
				return fmt.Errorf("invalid lxd-profile: contains device type %q", devType)
			}
		}
	}
	for key := range p.Config {
		if strings.HasPrefix(key, "boot") ||
			strings.HasPrefix(key, "limits") ||
			strings.HasPrefix(key, "migration") {
			return fmt.Errorf("invalid lxd-profile: contains config value %q", key)
		}
	}
	return nil
}
// ValidateConfigDevices implements LXDProfile interface.
ValidateConfigDevices implements LXDProfile interface.
// ValidateConfigDevices implements LXDProfile interface .
func (p Profile) ValidateConfigDevices() error {
	for _, val := range p.Devices {
		goodDevs := set.NewStrings("unix-char", "unix-block", "gpu", "usb")
		if devType, ok := val["type"]; ok {
			if !goodDevs.Contains(devType) {
				return fmt.Errorf("invalid lxd-profile: contains device type %q", devType)
			}
		}
	}
	for key := range p.Config {
		if strings.HasPrefix(key, "boot") ||
			strings.HasPrefix(key, "limits") ||
			strings.HasPrefix(key, "migration") {
			return fmt.Errorf("invalid lxd-profile: contains config value %q", key)
		}
	}
	return nil
}
func ( p Profile ) ValidateConfigDevices ( ) error { for _ , val := range p . Devices { goodDevs := set . NewStrings ( " " , " " , " " , " " ) if devType , ok := val [ " " ] ; ok { if ! goodDevs . Contains ( devType ) { return fmt . Errorf ( " " , devType ) } } } for key := range p . Config { if strings . HasPrefix ( key , " " ) || strings . HasPrefix ( key , " " ) || strings . HasPrefix ( key , " " ) { return fmt . Errorf ( " " , key ) } } return nil }
ValidateConfigDevices implements LXDProfile interface.
ValidateConfigDevices implements LXDProfile interface .