From 586eea808f241334c63dc2762f8704053cf4dfaa Mon Sep 17 00:00:00 2001 From: Gerald Pinder Date: Fri, 12 Sep 2025 12:05:52 -0400 Subject: [PATCH] Create base images too --- .gitlab-ci.yml | 2 ++ .../system/bootc-fetch-apply-updates.service | 9 +++++++++ .../systemd/system/bootc-fetch-apply-updates.timer | 14 ++++++++++++++ recipes/base-nvidia.yml | 14 ++++++++++++++ recipes/base.yml | 13 +++++++++++++ recipes/base/common.yml | 11 ----------- 6 files changed, 52 insertions(+), 11 deletions(-) create mode 100644 files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.service create mode 100644 files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.timer create mode 100644 recipes/base-nvidia.yml create mode 100644 recipes/base.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7501162..f7f8a0f 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -54,6 +54,8 @@ base-images: parallel: matrix: - RECIPE: + - base.yml + - base-nvidia.yml - base-cosmic.yml - base-cosmic-nvidia.yml - base-combo.yml diff --git a/files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.service b/files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.service new file mode 100644 index 0000000..5a6c484 --- /dev/null +++ b/files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.service @@ -0,0 +1,9 @@ +[Unit] +Description=Apply bootc updates +Documentation=man:bootc(8) +ConditionPathExists=/run/ostree-booted + +[Service] +Type=oneshot +# ExecStart=/usr/bin/bootc update --apply --quiet +ExecStart=/usr/bin/bootc update --quiet diff --git a/files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.timer b/files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.timer new file mode 100644 index 0000000..4ebb663 --- /dev/null +++ b/files/base/usr/lib/systemd/system/bootc-fetch-apply-updates.timer @@ -0,0 +1,14 @@ +[Unit] +Description=Apply bootc updates +Documentation=man:bootc(8) +ConditionPathExists=/run/ostree-booted + +[Timer] +OnBootSec=1h +# This time is relatively arbitrary and obviously expected to be overridden/changed +OnUnitInactiveSec=8h +# When deploying a large number of systems, it may be beneficial to increase this value to help with load on the registry. +RandomizedDelaySec=2h + +[Install] +WantedBy=timers.target diff --git a/recipes/base-nvidia.yml b/recipes/base-nvidia.yml new file mode 100644 index 0000000..48edc17 --- /dev/null +++ b/recipes/base-nvidia.yml @@ -0,0 +1,14 @@ +--- +# yaml-language-server: $schema=https://schema.blue-build.org/recipe-v1.json +name: cosmic +base-image: quay.io/fedora-ostree-desktops/base-atomic +image-version: 42 +description: The base image of Wunker OS +modules: + - from-file: base/common.yml + - from-file: base/nvidia.yml + - type: os-release + properties: + NAME: WunkerOS + PRETTY_NAME: Wunker OS for Nvidia + - from-file: base/post-build.yml diff --git a/recipes/base.yml b/recipes/base.yml new file mode 100644 index 0000000..d97a2ba --- /dev/null +++ b/recipes/base.yml @@ -0,0 +1,13 @@ +--- +# yaml-language-server: $schema=https://schema.blue-build.org/recipe-v1.json +name: cosmic +base-image: quay.io/fedora-ostree-desktops/base-atomic +image-version: 42 +description: The base image of Wunker OS +modules: + - from-file: base/common.yml + - type: os-release + properties: + NAME: WunkerOS + PRETTY_NAME: Wunker OS + - from-file: base/post-build.yml diff --git a/recipes/base/common.yml b/recipes/base/common.yml index c03998f..b5d9c5c 100644 --- a/recipes/base/common.yml +++ b/recipes/base/common.yml @@ -3,8 +3,6 @@ modules: - type: files files: - - source: bootc-update - destination: /usr/lib/systemd/system - source: base destination: / - type: systemd @@ -14,15 +12,6 @@ modules: enabled: - bootc-fetch-apply-updates.timer - # - type: dnf - # repos: - # cleanup: true - # copr: - # - ublue-os/packages - # - ublue-os/staging - # install: - # packages: - - type: dnf repos: cleanup: true