Skip to content

Return image fingerprint when building from base local/github images#73

Merged
beringresearch merged 1 commit intobravetools:masterfrom
Szubie:empty-image-fingerprint
May 25, 2022
Merged

Return image fingerprint when building from base local/github images#73
beringresearch merged 1 commit intobravetools:masterfrom
Szubie:empty-image-fingerprint

Conversation

@Szubie
Copy link
Collaborator

@Szubie Szubie commented May 25, 2022

Importing base images from public LXD servers set the fingerprint string, but other paths in the code left the image fingerprint at its default value (""), causing it to be impossible to delete image by fingerprint later. This would happen when the image base location was set to local. To address the problem, all import functions also return the image fingerprint when done.

This change allows for proper cleanup of images after build completion or in event of failure.

Also added cleanup of local image if importLocal fails to start a unit.

Together these should helps address problems caused by LXD images hanging around after a build, preventing future builds that attempt to use that alias.

… This ensures proper cleanup of images after build completion or in event of failure. Additionally, will cleanup local image as well as its unit if fail to start the unit.
@beringresearch beringresearch merged commit 5a40025 into bravetools:master May 25, 2022
@Szubie Szubie deleted the empty-image-fingerprint branch May 25, 2022 15:58
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

Successfully merging this pull request may close these issues.

2 participants