Commit Graph

39 Commits

Author SHA1 Message Date
Derek Higgins
4651913e55 Add a new break on error
A user running di-b several times while developing an element may not
want to drop to a shell in all cases but may only want to do so if one
of their in target hooks failed.

This patch gives them the ability to do so, If break=after-error is set
then a user will be provided a in target shell taking over from where the
last failed command left off.

Change-Id: Ia2f7ac4c21b64b971f87f4ae9cb867981b13eb5e
2013-08-01 17:08:54 +01:00
Clint Byrum
f57e8c66c2 Provide hint for what package contains qemu-img
While following install instructions in README.md it should be more
clear how to install qemu-img on your system.

Change-Id: Ibb8828806bf46716b91b83a4eea696f4fe478206
2013-07-27 17:05:20 +00:00
Robert Collins
f33c4ebdde Update TripleO incubator URL reference.
The old location has been deleted and 404's.

Change-Id: I29f3b534e28e8c0efe94736dcdc7f4c453738676
2013-07-23 15:18:05 +12:00
Robert Collins
b2f1d4e2af Document an interface for offline operation.
Complex image builds can download hundreds of MB of data from the
internet with many separate lookups. It would be nice to allow users
to ask for a fast build where those lookups are entirely avoided,
using locally cached resources (where possible). This new interface
allows users to signal to elements that they wish to operate without
updating cached resources, which will in turn allow us to avoid
checking for stale data at all.

As part of this I've also documented where we cache data, so that
things like the ccache cache dir and image cache files are not a
surprise to users.

Change-Id: I27f5de6ceaa4e9c6390721b7c434fe0908df84f5
2013-07-18 09:17:01 +12:00
Robert Collins
d1a24cab16 Move end user docs higher up in README.md.
Most folk probably don't need the massive design details, so they
should come later.

Change-Id: I94067196e664b37c05fbd8882d259ffc3d95c50f
2013-07-18 00:36:54 +12:00
Robert Collins
1a172683a5 Remove excess whitespace in README.md.
Change-Id: I664cfe4aa8d05c4cc53eeb2ee5f5a200f0d41110
2013-07-18 00:00:01 +12:00
Chris Jones
8d1ce9c0c3 Build ramdisks in an image chroot.
Ramdisks are now built inside a chroot which is built by the normal
image build process. Doing so improves our independence of the
precise state of the build host.

This fixes bug 1194055.

Change-Id: Ibc254fbb9e7b404b5f38c1b35bcde8a4136e8e28
2013-07-12 11:09:35 +01:00
Jenkins
8c5888e853 Merge "Adding docs for the source-repositories element" 2013-07-10 20:45:09 +00:00
Derek Higgins
195053108b Adding docs for the source-repositories element
Change-Id: I57244a5cc2f563b2e69eb49388c3c6b49202c9eb
2013-07-10 13:04:39 +01:00
Clint Byrum
3464064a87 Add environment.d hook to setup environment.
Before each phase dib-run-parts will pick these up to setup the
environment for the commands it runs.

Change-Id: I56697d7bc370918d4063eee67a1c35d4988a5359
2013-07-09 15:01:33 -07:00
Robert Collins
cbfd5a9a62 Document some dependencies.
Change-Id: Ibe925bd48cf8dd1a5318361ab972c5734aeee3c1
2013-06-07 15:20:21 +12:00
Robert Collins
fb246a02eb Ensure that the ext4 fs can be rebuilt up to 1PB in size.
Change-Id: I16c5fe4eb0a9951d44745d6a46450f70d33b3481
2013-05-18 13:08:06 +12:00
Chris Jones
7abd158346 Force text mode console in base element.
Apply kernel command line parameters to force Linux to remain in text
mode. Typical distro kernels quickly switch into a graphical screenmode
and this is incompatible with common Lights Out Management hardware
which is able to intercept text mode consoles to display them remotely.

Change-Id: Id553972c4fd87e78c9e6fe344331a399913d965e
2013-05-16 20:04:12 +01:00
Clint Byrum
d9a2211d14 Only use tmpfs if build machine has 4GB+ RAM.
For machines with low RAM (or no access to /proc/meminfo) the builder
will still run, but will just build inside the filesystem that is
hosting /tmp. This will result in a slower build (especially if there
are a lot of .deb packages installed).

Fixes bug #1175453

Change-Id: I79f2672058c11e377548820df0ab4fad8f47ffdc
2013-05-03 06:55:53 -07:00
Robert Collins
cb62bae9b8 Build images using loopdev instead of qemu-nbd.
Qemu-nbd does not perform well with older versions of qemu due to
the lack of writeback caching mode. It also only builds qcow2 images
and there is a desire for raw image support. Finally, qemu-nbd makes
it very difficult to build images concurrently due to the somewhat
opaque nature of how it selects a /dev/nbd# device. losetup, on
the other hand, makes this process very straight forward.

Change-Id: I309fad8af4fd1e8d1720c17b65e1897a76d5e897
Co-Author: Clint Byrum <clint@fewbar.com>
2013-04-30 08:56:12 -07:00
Lucas Alvares Gomes
45173ccdb5 Adds support for post-install scripts.
Post install scripts are useful because they can perform tasks you want
to handle after the OS/application install but before the first boot
of the image. e.g: Clean the cache left by the package manager reducing
the size of the image.

Change-Id: I03e77f602192bbdce29c02999d1b57fac8051ddc
Fixes: Bug #1145786
2013-04-17 09:47:51 +01:00
Chris Jones
bd1bae7c58 Introduce the DIB_ namespace for build-time config.
Document the use of DIB_ as a prefix on environmental variables that can
be overridden at build time.

Introduce the first such variable by migrating IMAGE_SIZE to
DIB_IMAGE_SIZE.

Change-Id: Ie36b734991b913a23f37f2add47d470d7c1576e4
2013-04-12 09:50:34 +01:00
Robert Collins
5ada82a59c Add armhf support.
ARM doesn't have a generic Linux image due to the soc-specific nature of Linux
kernels today, so we drop the manual installation of that package, replacing it
with a dist-upgrade instead. This involved tweaks to the dpkg and fedora
install-package scripts.

Change-Id: I97924b80ca87781307e1087b9fe4b18215770e84
2013-04-09 08:17:22 +12:00
Robert Collins
24c89932be Always include the in-tree elements directory.
Change-Id: I5a79fbf0568f5755dd14824ed147093387170b3f
2013-04-08 10:26:44 +12:00
Robert Collins
e826e77a16 Delete elements moved to tripleo-image-elements.
Change-Id: I062d3dfb538682d72011307e8b96672e8f0844a5
2013-04-07 07:08:00 +12:00
Chris Jones
ddcf3db028 Update README.md for build-time state capture
Document the existence and genesis of /etc/dib_{environment,arguments}

Change-Id: I99e696b87230d3b45ae1d37ee0de3742f407f0ce
2013-04-05 10:00:52 +01:00
Ghe Rivero
308eee2827 Use multiple locations for elements dir.
Using ELEMENTS_DIR env variable, you can specify multiple dirs containint your elements.
It must be a ":" separated elements list.

When an element is seen in one of those lists, it will be chosen and will continue with the next element.

Change-Id: I18eca27d943139cd6ca1ebd232b419e502d7b048
2013-02-27 10:48:55 +01:00
Robert Collins
9afddcf266 New element that uses a fedora cloud image as the base.
Change-Id: I7d83bb2b359e7a8c3858eca04c96e35cf4e1fe9e
2013-02-15 09:33:29 +13:00
Robert Collins
7f77729ec5 Move the dpkg specific stuff to a dpkg element rather than being hardcoded.
This includes the install-packages implementation for dpkg, apt http proxy
config, daemon blocking and unblocking.

Change-Id: I8f159021d2b223d7003cec067de3aa605ad06974
2013-02-14 11:16:12 +13:00
Robert Collins
1ee3a01447 Move initial root contents into a hook.
This is a necessary but not complete step towards supporting Fedora and Suse
distributions. Further work is needed (e.g. to quiesce daemons on
installation).

Change-Id: If3ea6093d41a21de755db52328226b84b5a3ede6
2013-02-11 17:01:36 +13:00
Clint Byrum
c8c33e3bb1 Add a simple implementation of element dependency
This adds a new optional file to the root of elements. The
file lists dependencies which will be added to the list
requested by the user during disk image creation.

Change-Id: Id71c3b333563604bbbaf90f9cf40e24fa9738fc8
2013-01-23 16:04:20 -08:00
Monty Taylor
d0e9f98b5b Replace demo references with incubator.
Change-Id: I94e88471e85ab5cf364ce995d6e09631030e3aeb
2012-12-19 15:07:48 -08:00
Chris Jones
2cefdd7e60 Tidy up base element:
Fix a typo in the base element itself.
Refer to it early in the README since it is likely to be useful to
almost everyone.

Change-Id: I4a753b61542f8a354ade7fcc4436076aec61e6c0
2012-12-17 16:53:46 +00:00
Devananda van der Veen
d212ffd1db Add guidelines for composing elements.
Change-Id: Id9bb81aefaad2024d9a73d02c58a73565250b813
2012-12-16 18:49:38 -08:00
Robert Collins
1f39f4c629 Add a test framework for testing elements.
Change-Id: I845ac3ec6bbcd212ee43151981a2bc5264f4a5b3
2012-12-14 20:17:39 +13:00
Robert Collins
d03825b504 Add the ability to break into a shell during builds.
Change-Id: I87af952d892f8622e4c916085fc896c735a35438
2012-12-14 20:17:29 +13:00
Monty Taylor
1eff4a436e Rename flavour to element.
Flavour is overloaded in openstack due to it being used by nova. Element
seems to have the same feeling of combinability without using a term already
in active use in the openstack community.

Change-Id: Ia4c028d4062a8f69c66665821c94dd4bcdf06031
2012-12-05 14:04:58 -08:00
Robert Collins
4b7cdb4fdc Fix copyrights for HP work. 2012-11-15 16:20:32 +13:00
Robert Collins
823e18fda2 Document more about the layers. 2012-11-13 10:00:33 +13:00
Robert Collins
40e954735c Make it possible to set a size from within a flavour, and use that for devstack. 2012-11-12 11:47:26 +13:00
Robert Collins
ac930076fb Rename baremetal to deploy. 2012-11-10 11:36:24 +13:00
Chris Jones
88a11115f5 Update docs for ramdisk building 2012-11-09 22:15:05 +00:00
Robert Collins
511fb825f9 Documented binary-deps feature. 2012-11-10 10:50:15 +13:00
Robert Collins
5cc195e391 Bring across disk image code. 2012-11-10 00:04:13 +13:00