Enable parallel builds using diskimage-builder

Registered by azher ullah khan on 2014-07-28

Background:
Currently if you run parallel builds for diskimage-builder on a system the builds fail, because the diskimage-builder uses the common “~/.cache/image-create” directory to cache OS image files, git repositories, Python or Ruby packages etc. to create the images.

Proposal:
If we want to enable parallel builds, then we need to identify and tie the builds to the correct “~/.cache/image-create” folder. To do this we can use mktemp and let diskimage-builder use this directory as the cache directory instead of “DIB_IMAGE_CACHE” (~/.cache/image-create).

    export CACHE_DIR=$(mktemp -d ~/.cache/image-create.XXXXXXXX)

This will create the "~/.cache/image-create.XXXXXXXX" directory and let the diskimage-builder use it for its respective builds.

Also, to enable diskimage-builder to build with the correct "~/.cache/image-create.XXXXXXXX" directory for “--offline” mode; the script should force the user to specify the respective “image-create.XXXXXXXX” folder to refer to for the build.

Blueprint information

Status:
Complete
Approver:
Divakar Padiyar Nandavar
Priority:
Undefined
Drafter:
azher ullah khan
Direction:
Needs approval
Assignee:
None
Definition:
Obsolete
Series goal:
None
Implementation:
Unknown
Milestone target:
None
Completed by
Steven Hardy on 2016-04-21

Related branches

Sprints

Whiteboard

(?)

Work Items

This blueprint contains Public information 
Everyone can see this information.