From 5d61ba5d3939acbe7095131bb9cc476bec3e180f Mon Sep 17 00:00:00 2001 From: Achilleas Koutsou Date: Mon, 15 Aug 2022 22:21:59 +0200 Subject: [PATCH] image: add OSTreeRawImage ImageKind MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit InstantiateManifest is a stub. No implementation yet. Co-Authored-By: Ondřej Budai --- internal/image/ostree_raw.go | 42 ++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 internal/image/ostree_raw.go diff --git a/internal/image/ostree_raw.go b/internal/image/ostree_raw.go new file mode 100644 index 000000000..d9a7838d8 --- /dev/null +++ b/internal/image/ostree_raw.go @@ -0,0 +1,42 @@ +package image + +import ( + "math/rand" + + "github.com/osbuild/osbuild-composer/internal/artifact" + "github.com/osbuild/osbuild-composer/internal/disk" + "github.com/osbuild/osbuild-composer/internal/manifest" + "github.com/osbuild/osbuild-composer/internal/platform" + "github.com/osbuild/osbuild-composer/internal/rpmmd" + "github.com/osbuild/osbuild-composer/internal/runner" + "github.com/osbuild/osbuild-composer/internal/workload" +) + +type OSTreeRawImage struct { + Base + Platform platform.Platform + Workload workload.Workload + PartitionTable *disk.PartitionTable + + OSTreeURL string + OSTreeRef string + OSTreeCommit string + + Remote string + OSName string + + Filename string +} + +func NewOSTreeRawImage() *OSTreeRawImage { + return &OSTreeRawImage{ + Base: NewBase("ostree-raw-image"), + } +} + +func (img *OSTreeRawImage) InstantiateManifest(m *manifest.Manifest, + repos []rpmmd.RepoConfig, + runner runner.Runner, + rng *rand.Rand) (*artifact.Artifact, error) { + return nil, nil +}