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

image-handling.md: 'release' should be a string and not a list #5381

Merged
merged 1 commit into from Dec 27, 2018

Conversation

3 participants
@TerraTech
Copy link
Contributor

TerraTech commented Dec 27, 2018

During 'lxc image import', yaml.Unmarshal() and is applied to the following struct:

  // ImageMetadata represents LXD image metadata
  type ImageMetadata struct {
	Architecture string                            `json:"architecture" yaml:"architecture"`
	CreationDate int64                             `json:"creation_date" yaml:"creation_date"`
	ExpiryDate   int64                             `json:"expiry_date" yaml:"expiry_date"`
	Properties   map[string]string                 `json:"properties" yaml:"properties"`
	Templates    map[string]*ImageMetadataTemplate `json:"templates" yaml:"templates"`
  }

ImageMetadata.Properties is a map[string]string, and applying any property as a list will
result in the following error:

Error: Could not parse metadata.yaml: yaml: unmarshal errors:
line 8: cannot unmarshal !!seq into string

Signed-off-by: fqbuild TerraTech@users.noreply.github.com

image-handling.md: 'release' should be a string and not a list
  During 'lxc image import', yaml.Unmarshal() and is applied to the following struct:

  // ImageMetadata represents LXD image metadata
  type ImageMetadata struct {
	Architecture string                            `json:"architecture" yaml:"architecture"`
	CreationDate int64                             `json:"creation_date" yaml:"creation_date"`
	ExpiryDate   int64                             `json:"expiry_date" yaml:"expiry_date"`
	Properties   map[string]string                 `json:"properties" yaml:"properties"`
	Templates    map[string]*ImageMetadataTemplate `json:"templates" yaml:"templates"`
  }

  ImageMetadata.Properties is a map[string]string, and applying any property as a list will
  result in the following error:

  >> Error: Could not parse metadata.yaml: yaml: unmarshal errors:
  >> line 8: cannot unmarshal !!seq into string

Signed-off-by: fqbuild <TerraTech@users.noreply.github.com>
@lxc-jenkins

This comment has been minimized.

Copy link

lxc-jenkins commented Dec 27, 2018

This pull request didn't trigger Jenkins as its author isn't in the whitelist.

An organization member must perform one of the following:

  • To have this branch tested by Jenkins, use the "ok to test" command.
  • To have a one time test done, use the "test this please" command.

Those commands are simple Github comments of the format: "jenkins: COMMAND"

@stgraber stgraber merged commit 6556fcb into lxc:master Dec 27, 2018

4 checks passed

Branch target Branch target is correct
Details
DCO All commits signed-off
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment