Skip to content
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

"images" command fails with last image error #362

Open
movitto opened this issue Dec 8, 2015 · 0 comments
Open

"images" command fails with last image error #362

movitto opened this issue Dec 8, 2015 · 0 comments

Comments

@movitto
Copy link

movitto commented Dec 8, 2015

Background:

  • occurs when imagefactory is not run as sudo
  • user does not have access to write to /var/log/imagefactory.log
  • default imagefactory output is "log"
  • /usr/bin/imagefactory writes the status_details of the image stored in "image", set in the context of the build and delete commands
  • the "images" command iterates over retrieved images and assigns to the "image" variable, resulting in the last image's error being output

https://github.com/redhat-imaging/imagefactory/blob/master/imagefactory#L248

Reproduce:
Delete images, generate a failed one, run the following as a regular / non-privileged user:
$ imagefactory images '{"type": "BaseImage"}'

Fix:
Assign images being iterated over to a variable other than "image" in /usr/bin/imagefactor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant