Commit graph

13 commits

Author SHA1 Message Date
Achilleas Koutsou
822571e28e manifest: support specifying force_size for VPC
The RHEL 7 vpc subformat in qemu does not support force_size so we need
to be able to disable it.  The parameter in all parts is defined as a
pointer because the default value is 'true'.  Not specifying it will
keep the option in the osbuild stage as 'nil', falling back to 'true' in
osbuild.
2023-01-25 20:37:12 +01:00
Achilleas Koutsou
458f51128a manifest: set default VPC filename to image.vhd 2022-11-28 17:20:49 +01:00
Tom Gundersen
ce40e1d810 artifact: this represents the artifacts a manifest exports
For now this encapsulates osbuild export and filename in that
exported tree. In the future we could add MIME type.

For now this is a concrete type, but should probably be an
interface, so the consumer of artefacts know they are the right
type. Enforcing we only push AMIs to EC2, etc.

Similarly to how checkpoints work, each pipeline can be marked for
export, and the manifest can return all the names of the exported
pipelines, to be passed to osbuild. Additionally, the Export
function returns an artefact object, which can be used to know how
to access the exports once osbuild is done. For now, this is unused.
2022-07-22 16:04:07 +02:00
Achilleas Koutsou
9d4a351ca6 Rename osbuild2 package to osbuild 2022-07-14 16:54:00 +02:00
Tom Gundersen
e844453c85 manifest: make filename optional and generalise Tree
We have three kinds of operating system trees, until we unify them to one,
hide them behind one interface. Use this to read the architecture from the
Tree rather than pass it in as a string to parent pipelines.

Also, make the filename parameter optional in a few places, there should be no
reason to set this rather than introspect it (except for backwards
compatibility).

Lastly, add another playground example sample to build a raw image.
2022-07-12 08:19:57 +01:00
Tom Gundersen
d00b98c134 manifest: don't stutter
Replace `pipeline.OSPipeline` with `pipeline.OS`, etc.

Also rename `LiveImg` to `RawImage`.
2022-07-12 08:19:57 +01:00
Tom Gundersen
529bc803db runner: introduce runner abstraction
For now all it does is represent the name of the runner and what requirements
it has of the build pipeline.

Move some package definitions from the runner package set to where it belongs.
2022-07-12 08:19:57 +01:00
Tom Gundersen
9160319152 manifest/build: move out qemu-img
Let each pipeline that requires it pull in qemu-img.
2022-07-12 08:19:57 +01:00
Tom Gundersen
4961a17ba8 manifest: implicitly track pipelines in manifest
Pipelines are now added to their manifest on creation, and we
ensure that dependants are associated with the same manifest.
2022-07-04 23:04:29 +01:00
Tom Gundersen
fc08579c29 manifest/build: implement getPackageSetChain
A build pipeline now tracks all its dependents, and each pipeline
now implements a `getBuildPackages()` method. For now those
return the empty slice, but will be extended by each pipeline in the
future.

`getPackageSetChain() of the build pipeline simply collects all the
build package sets of its dependents.
2022-07-04 23:04:29 +01:00
Tom Gundersen
0743eb2f81 manifest: use call-by-reference in pipeline interface
This allows interface methods to modify the state of the pipeline
objects. We will use this in subsequent patches.
2022-07-04 23:04:29 +01:00
Tom Gundersen
6940853215 manifest: remove unused public functions from pipelines
These were only used from the manifest package, make them internal,
or read private fields directly.
2022-07-04 23:04:29 +01:00
Tom Gundersen
f791bde0e4 pipeline: fully encapsulate manifest generation
Make it the responsibility of each pipeline to track its required
sources, and use this to generate a manifest from its pipelines.

This removes the dependency on osbuild2 from distro.go, and the
only other uses of osbuild2 are to specify parameters in
ImageConfig, which will eventually go away too.

As a consequence, this only attaches the required sources for a
given manifest, rather than all known packages in the package set
map.
2022-07-04 23:04:29 +01:00
Renamed from internal/pipeline/vpc.go (Browse further)