From 88f5b2f74018ce7eac8ed616ba8e9ad8051d4dea Mon Sep 17 00:00:00 2001 From: SUSE Update Bot Date: Mon, 20 Jan 2025 10:07:35 +0000 Subject: [PATCH] Test build for #2210 --- .obs/workflows.yml | 21 +++++++ firefox-image/Dockerfile | 55 ++++++++++++++++++ firefox-image/README.md | 17 ++++++ firefox-image/_service | 10 ++++ firefox-image/firefox-image.changes | 4 ++ git-image/Dockerfile | 56 +++++++++++++++++++ git-image/_service | 6 +- git-image/config.sh | 31 ----------- git-image/git-image.kiwi | 68 ----------------------- pulseaudio-image/Dockerfile | 55 ++++++++++++++++++ pulseaudio-image/README.md | 17 ++++++ pulseaudio-image/_service | 10 ++++ pulseaudio-image/client.conf | 2 + pulseaudio-image/daemon.conf | 6 ++ pulseaudio-image/pulseaudio-image.changes | 4 ++ pulseaudio-image/system.pa | 39 +++++++++++++ x11-image/Dockerfile | 63 +++++++++++++++++++++ x11-image/README.md | 17 ++++++ x11-image/_service | 10 ++++ x11-image/entrypoint.sh | 54 ++++++++++++++++++ x11-image/preferences | 4 ++ x11-image/x11-image.changes | 4 ++ x11-image/xinitrc | 13 +++++ x11-image/xorg.conf | 43 ++++++++++++++ 24 files changed, 507 insertions(+), 102 deletions(-) create mode 100644 firefox-image/Dockerfile create mode 100644 firefox-image/README.md create mode 100644 firefox-image/_service create mode 100644 firefox-image/firefox-image.changes create mode 100644 git-image/Dockerfile delete mode 100644 git-image/config.sh delete mode 100644 git-image/git-image.kiwi create mode 100644 pulseaudio-image/Dockerfile create mode 100644 pulseaudio-image/README.md create mode 100644 pulseaudio-image/_service create mode 100644 pulseaudio-image/client.conf create mode 100644 pulseaudio-image/daemon.conf create mode 100644 pulseaudio-image/pulseaudio-image.changes create mode 100644 pulseaudio-image/system.pa create mode 100644 x11-image/Dockerfile create mode 100644 x11-image/README.md create mode 100644 x11-image/_service create mode 100644 x11-image/entrypoint.sh create mode 100644 x11-image/preferences create mode 100644 x11-image/x11-image.changes create mode 100644 x11-image/xinitrc create mode 100644 x11-image/xorg.conf diff --git a/.obs/workflows.yml b/.obs/workflows.yml index 2b6c63362..89ea2d05d 100644 --- a/.obs/workflows.yml +++ b/.obs/workflows.yml @@ -49,6 +49,10 @@ staging_build: source_project: home:defolos:BCI:CR:SLE-15-SP7 source_package: dotnet-9.0 target_project: home:defolos:BCI:CR:SLE-15-SP7:Staging + - branch_package: + source_project: home:defolos:BCI:CR:SLE-15-SP7 + source_package: firefox-image + target_project: home:defolos:BCI:CR:SLE-15-SP7:Staging - branch_package: source_project: home:defolos:BCI:CR:SLE-15-SP7 source_package: gcc-14-image @@ -157,6 +161,10 @@ staging_build: source_project: home:defolos:BCI:CR:SLE-15-SP7 source_package: prometheus-image target_project: home:defolos:BCI:CR:SLE-15-SP7:Staging + - branch_package: + source_project: home:defolos:BCI:CR:SLE-15-SP7 + source_package: pulseaudio-image + target_project: home:defolos:BCI:CR:SLE-15-SP7:Staging - branch_package: source_project: home:defolos:BCI:CR:SLE-15-SP7 source_package: python-3.11-image @@ -209,6 +217,10 @@ staging_build: source_project: home:defolos:BCI:CR:SLE-15-SP7 source_package: stunnel-image target_project: home:defolos:BCI:CR:SLE-15-SP7:Staging + - branch_package: + source_project: home:defolos:BCI:CR:SLE-15-SP7 + source_package: x11-image + target_project: home:defolos:BCI:CR:SLE-15-SP7:Staging filters: event: pull_request @@ -262,6 +274,9 @@ refresh_devel_BCI: - trigger_services: project: devel:BCI:SLE-15-SP7 package: dotnet-9.0 + - trigger_services: + project: devel:BCI:SLE-15-SP7 + package: firefox-image - trigger_services: project: devel:BCI:SLE-15-SP7 package: gcc-14-image @@ -343,6 +358,9 @@ refresh_devel_BCI: - trigger_services: project: devel:BCI:SLE-15-SP7 package: prometheus-image + - trigger_services: + project: devel:BCI:SLE-15-SP7 + package: pulseaudio-image - trigger_services: project: devel:BCI:SLE-15-SP7 package: python-3.11-image @@ -382,6 +400,9 @@ refresh_devel_BCI: - trigger_services: project: devel:BCI:SLE-15-SP7 package: stunnel-image + - trigger_services: + project: devel:BCI:SLE-15-SP7 + package: x11-image filters: event: push branches: diff --git a/firefox-image/Dockerfile b/firefox-image/Dockerfile new file mode 100644 index 000000000..b1d2ea897 --- /dev/null +++ b/firefox-image/Dockerfile @@ -0,0 +1,55 @@ +# SPDX-License-Identifier: MIT + +# Copyright (c) 2025 SUSE LLC + +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. + +# The content of THIS FILE IS AUTOGENERATED and should not be manually modified. +# It is maintained by the BCI team and generated by +# https://github.com/SUSE/BCI-dockerfile-generator + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# You can contact the BCI team via https://github.com/SUSE/bci/discussions + +#!UseOBSRepositories + +#!BuildTag: bci/firefox:%%ff_ver%%-%RELEASE% +#!BuildTag: bci/firefox:%%ff_ver%% +#!BuildTag: bci/firefox:128.6 +#!BuildName: bci-firefox-128.6 +#!BuildVersion: 15.7.128.6 +FROM bci/bci-base:15.7 + +RUN set -euo pipefail; \ + zypper -n install --no-recommends MozillaFirefox MozillaFirefox-branding-SLE gconf2; \ + zypper -n clean; \ + rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2} + +# Define labels according to https://en.opensuse.org/Building_derived_containers +# labelprefix=com.suse.bci.firefox +LABEL org.opencontainers.image.authors="https://github.com/SUSE/bci/discussions" +LABEL org.opencontainers.image.title="SLE BCI Mozilla Firefox" +LABEL org.opencontainers.image.description="Mozilla Firefox container based on the SLE Base Container Image." +LABEL org.opencontainers.image.version="%%ff_ver%%" +LABEL org.opencontainers.image.url="https://www.suse.com/products/base-container-images/" +LABEL org.opencontainers.image.created="%BUILDTIME%" +LABEL org.opencontainers.image.vendor="SUSE LLC" +LABEL org.opencontainers.image.source="%SOURCEURL%" +LABEL org.opencontainers.image.ref.name="%%ff_ver%%-%RELEASE%" +LABEL org.opensuse.reference="registry.suse.com/bci/firefox:%%ff_ver%%-%RELEASE%" +LABEL org.openbuildservice.disturl="%DISTURL%" +LABEL com.suse.supportlevel="techpreview" +LABEL com.suse.eula="sle-bci" +LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle#suse-linux-enterprise-server-15" +LABEL com.suse.release-stage="beta" +# endlabelprefix +LABEL io.artifacthub.package.readme-url="%SOURCEURL%/README.md" +CMD ["/bin/bash", "-c", "firefox --kiosk $URL"] +# sanity check that the version from the tag is equal to the version of MozillaFirefox that we expect +RUN set -euo pipefail; \ + [ "$(rpm -q --qf '%{version}' MozillaFirefox | \ + cut -d '.' -f -2)" = "128.6" ] +RUN useradd -m user -u 1000 +ENV DISPLAY=":0" diff --git a/firefox-image/README.md b/firefox-image/README.md new file mode 100644 index 000000000..a31351394 --- /dev/null +++ b/firefox-image/README.md @@ -0,0 +1,17 @@ +# The SLE BCI Mozilla Firefox container image +![Redistributable](https://img.shields.io/badge/Redistributable-Yes-green)![Support Level](https://img.shields.io/badge/Support_Level-techpreview-blue)[![SLSA](https://img.shields.io/badge/SLSA_(v1.0)-Build_L3-Green)](https://documentation.suse.com/sbp/server-linux/html/SBP-SLSA4/) +[![Provenance: Available](https://img.shields.io/badge/Provenance-Available-Green)](https://documentation.suse.com/container/all/html/Container-guide/index.html#container-verify) + +Mozilla Firefox container based on the SLE Base Container Image. + +## Licensing + +`SPDX-License-Identifier: MIT` + +This documentation and the build recipe are licensed as MIT. +The container itself contains various software components under various open source licenses listed in the associated +Software Bill of Materials (SBOM). + +This image is a tech preview. Do not use it for production. +Your feedback is welcome. +Please report any issues to the [SUSE Bugzilla](https://bugzilla.suse.com/enter_bug.cgi?product=SUSE%20Linux%20Enterprise%20Base%20Container%20Images). diff --git a/firefox-image/_service b/firefox-image/_service new file mode 100644 index 000000000..4099a821b --- /dev/null +++ b/firefox-image/_service @@ -0,0 +1,10 @@ + + + + + Dockerfile + %%ff_ver%% + MozillaFirefox + minor + + \ No newline at end of file diff --git a/firefox-image/firefox-image.changes b/firefox-image/firefox-image.changes new file mode 100644 index 000000000..6fd7a99ab --- /dev/null +++ b/firefox-image/firefox-image.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Mon Jan 20 10:07:35 UTC 2025 - SUSE Update Bot + +- First version of the Mozilla Firefox BCI diff --git a/git-image/Dockerfile b/git-image/Dockerfile new file mode 100644 index 000000000..7570e67d8 --- /dev/null +++ b/git-image/Dockerfile @@ -0,0 +1,56 @@ +# SPDX-License-Identifier: GPL-2.0-only + +# Copyright (c) 2025 SUSE LLC + +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. + +# The content of THIS FILE IS AUTOGENERATED and should not be manually modified. +# It is maintained by the BCI team and generated by +# https://github.com/SUSE/BCI-dockerfile-generator + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# You can contact the BCI team via https://github.com/SUSE/bci/discussions + +#!UseOBSRepositories + +#!BuildTag: suse/git:%%git_version%%-%RELEASE% +#!BuildTag: suse/git:%%git_version%% +#!BuildTag: suse/git:2.43 +#!BuildTag: suse/git:%%git_major_version%% +#!BuildName: suse-git-2.43 +#!BuildVersion: 15.7.2.43 +FROM bci/bci-micro:15.7 AS target +FROM suse/sle15:15.7 AS builder +COPY --from=target / /target + +RUN set -euo pipefail; \ + zypper -n --installroot /target --gpg-auto-import-keys install --no-recommends git-core openssh-clients; \ + zypper -n clean; \ + rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2} +# sanity check that the version from the tag is equal to the version of git-core that we expect +RUN set -euo pipefail; \ + [ "$(rpm --root /target -q --qf '%{version}' git-core | \ + cut -d '.' -f -2)" = "2.43" ] +FROM bci/bci-micro:15.7 +COPY --from=builder /target / +# Define labels according to https://en.opensuse.org/Building_derived_containers +# labelprefix=com.suse.application.git +LABEL org.opencontainers.image.authors="https://github.com/SUSE/bci/discussions" +LABEL org.opencontainers.image.title="SLE 15 SP7 with Git" +LABEL org.opencontainers.image.description="A micro environment with Git based on the SLE Base Container Image." +LABEL org.opencontainers.image.version="%%git_version%%" +LABEL org.opencontainers.image.url="https://www.suse.com/products/base-container-images/" +LABEL org.opencontainers.image.created="%BUILDTIME%" +LABEL org.opencontainers.image.vendor="SUSE LLC" +LABEL org.opencontainers.image.source="%SOURCEURL%" +LABEL org.opencontainers.image.ref.name="%%git_version%%-%RELEASE%" +LABEL org.opensuse.reference="registry.suse.com/suse/git:%%git_version%%-%RELEASE%" +LABEL org.openbuildservice.disturl="%DISTURL%" +LABEL com.suse.supportlevel="techpreview" +LABEL com.suse.eula="sle-eula" +LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle#suse-linux-enterprise-server-15" +LABEL com.suse.release-stage="beta" +# endlabelprefix +LABEL io.artifacthub.package.readme-url="%SOURCEURL%/README.md" diff --git a/git-image/_service b/git-image/_service index 7af8eaa71..b2b3c7d2d 100644 --- a/git-image/_service +++ b/git-image/_service @@ -1,13 +1,13 @@ - + - git-image.kiwi + Dockerfile %%git_version%% git-core - git-image.kiwi + Dockerfile %%git_major_version%% git-core major diff --git a/git-image/config.sh b/git-image/config.sh deleted file mode 100644 index ab0e8d671..000000000 --- a/git-image/config.sh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash -# SPDX-License-Identifier: MIT -# SPDX-FileCopyrightText: (c) 2022-2025 SUSE LLC - -set -euo pipefail - -test -f /.kconfig && . /.kconfig -test -f /.profile && . /.profile - -echo "Configure image: [$kiwi_iname]..." - -#============================================ -# Import repositories' keys if rpm is present -#-------------------------------------------- -if command -v rpm > /dev/null; then - suseImportBuildKey -fi - - - - -#======================================= -# Clean up after zypper if it is present -#--------------------------------------- -if command -v zypper > /dev/null; then - zypper -n clean -fi - -rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2} - -exit 0 diff --git a/git-image/git-image.kiwi b/git-image/git-image.kiwi deleted file mode 100644 index 95938f9af..000000000 --- a/git-image/git-image.kiwi +++ /dev/null @@ -1,68 +0,0 @@ - - - - - - - - - SUSE LLC - https://www.suse.com/ - SLE 15 SP7 with Git Container Image - - - - - - - - - - - 15.7.0 - zypper - false - true - - - - - - - - - - - \ No newline at end of file diff --git a/pulseaudio-image/Dockerfile b/pulseaudio-image/Dockerfile new file mode 100644 index 000000000..de953a617 --- /dev/null +++ b/pulseaudio-image/Dockerfile @@ -0,0 +1,55 @@ +# SPDX-License-Identifier: MIT + +# Copyright (c) 2025 SUSE LLC + +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. + +# The content of THIS FILE IS AUTOGENERATED and should not be manually modified. +# It is maintained by the BCI team and generated by +# https://github.com/SUSE/BCI-dockerfile-generator + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# You can contact the BCI team via https://github.com/SUSE/bci/discussions + +#!UseOBSRepositories + +#!BuildTag: suse/pulseaudio:%%pulseaudio_ver%%-%RELEASE% +#!BuildTag: suse/pulseaudio:%%pulseaudio_ver%% +#!BuildTag: suse/pulseaudio:17 +#!BuildName: suse-pulseaudio-17 +#!BuildVersion: 15.7.17 +FROM suse/sle15:15.7 + +RUN set -euo pipefail; \ + zypper -n install --no-recommends pulseaudio pulseaudio-utils; \ + zypper -n clean; \ + rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2} + +# Define labels according to https://en.opensuse.org/Building_derived_containers +# labelprefix=com.suse.application.pulseaudio +LABEL org.opencontainers.image.authors="https://github.com/SUSE/bci/discussions" +LABEL org.opencontainers.image.title="SLE Pulseaudio" +LABEL org.opencontainers.image.description="Pulseaudio container based on the SLE Base Container Image." +LABEL org.opencontainers.image.version="%%pulseaudio_ver%%" +LABEL org.opencontainers.image.url="https://www.suse.com/products/base-container-images/" +LABEL org.opencontainers.image.created="%BUILDTIME%" +LABEL org.opencontainers.image.vendor="SUSE LLC" +LABEL org.opencontainers.image.source="%SOURCEURL%" +LABEL org.opencontainers.image.ref.name="%%pulseaudio_ver%%-%RELEASE%" +LABEL org.opensuse.reference="registry.suse.com/suse/pulseaudio:%%pulseaudio_ver%%-%RELEASE%" +LABEL org.openbuildservice.disturl="%DISTURL%" +LABEL com.suse.supportlevel="techpreview" +LABEL com.suse.eula="sle-eula" +LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle#suse-linux-enterprise-server-15" +LABEL com.suse.release-stage="beta" +# endlabelprefix +LABEL io.artifacthub.package.readme-url="%SOURCEURL%/README.md" +# sanity check that the version from the tag is equal to the version of pulseaudio that we expect +RUN set -euo pipefail; \ + [ "$(rpm -q --qf '%{version}' pulseaudio | \ + cut -d '.' -f -1)" = "17" ] +COPY daemon.conf /etc/pulse/ +COPY client.conf /etc/pulse/ +COPY system.pa /etc/pulse/ diff --git a/pulseaudio-image/README.md b/pulseaudio-image/README.md new file mode 100644 index 000000000..0750ee214 --- /dev/null +++ b/pulseaudio-image/README.md @@ -0,0 +1,17 @@ +# The SLE Pulseaudio container image +![Support Level](https://img.shields.io/badge/Support_Level-techpreview-blue)[![SLSA](https://img.shields.io/badge/SLSA_(v1.0)-Build_L3-Green)](https://documentation.suse.com/sbp/server-linux/html/SBP-SLSA4/) +[![Provenance: Available](https://img.shields.io/badge/Provenance-Available-Green)](https://documentation.suse.com/container/all/html/Container-guide/index.html#container-verify) + +Pulseaudio container based on the SLE Base Container Image. + +## Licensing + +`SPDX-License-Identifier: MIT` + +This documentation and the build recipe are licensed as MIT. +The container itself contains various software components under various open source licenses listed in the associated +Software Bill of Materials (SBOM). + +This image is a tech preview. Do not use it for production. +Your feedback is welcome. +Please report any issues to the [SUSE Bugzilla](https://bugzilla.suse.com/enter_bug.cgi?product=SUSE%20Linux%20Enterprise%20Base%20Container%20Images). diff --git a/pulseaudio-image/_service b/pulseaudio-image/_service new file mode 100644 index 000000000..5241722ec --- /dev/null +++ b/pulseaudio-image/_service @@ -0,0 +1,10 @@ + + + + + Dockerfile + %%pulseaudio_ver%% + pulseaudio + minor + + \ No newline at end of file diff --git a/pulseaudio-image/client.conf b/pulseaudio-image/client.conf new file mode 100644 index 000000000..73f8927b3 --- /dev/null +++ b/pulseaudio-image/client.conf @@ -0,0 +1,2 @@ +autospawn = no +auto-connect-localhost = yes diff --git a/pulseaudio-image/daemon.conf b/pulseaudio-image/daemon.conf new file mode 100644 index 000000000..6765f9638 --- /dev/null +++ b/pulseaudio-image/daemon.conf @@ -0,0 +1,6 @@ +daemonize = no +fail = no +; allow-module-loading = yes +allow-exit = no +use-pid-file = no +system-instance = yes diff --git a/pulseaudio-image/pulseaudio-image.changes b/pulseaudio-image/pulseaudio-image.changes new file mode 100644 index 000000000..39fdf79ec --- /dev/null +++ b/pulseaudio-image/pulseaudio-image.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Mon Jan 20 10:07:35 UTC 2025 - SUSE Update Bot + +- First version of the Pulseaudio BCI diff --git a/pulseaudio-image/system.pa b/pulseaudio-image/system.pa new file mode 100644 index 000000000..5094cc2fb --- /dev/null +++ b/pulseaudio-image/system.pa @@ -0,0 +1,39 @@ +#!/usr/bin/pulseaudio -nF +.fail + +### Automatically restore the volume of streams and devices +load-module module-device-restore +load-module module-stream-restore +load-module module-card-restore + +load-module module-udev-detect + +### Load several protocols +.ifexists module-esound-protocol-unix.so +load-module module-esound-protocol-unix +.endif +load-module module-native-protocol-unix auth-anonymous=1 + +load-module module-native-protocol-tcp auth-anonymous=1 auth-ip-acl=127.0.0.1 + +load-module module-default-device-restore + +### Make sure we always have a sink around, even if it is a null sink. +load-module module-always-sink + +### Automatically suspend sinks/sources that become idle for too long +load-module module-suspend-on-idle + +### Enable positioned event sounds +load-module module-position-event-sounds + +.nofail + +### Set the default sink +#set-default-sink alsa_output.pci-0000_00_1b.0.analog-stereo + +### Set default sink volume to 100% +set-sink-volume @DEFAULT_SINK@ 0x10000 + +### Unmute default sink +set-sink-mute @DEFAULT_SINK@ 0 diff --git a/x11-image/Dockerfile b/x11-image/Dockerfile new file mode 100644 index 000000000..bfc4d1c9d --- /dev/null +++ b/x11-image/Dockerfile @@ -0,0 +1,63 @@ +# SPDX-License-Identifier: MIT + +# Copyright (c) 2025 SUSE LLC + +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. + +# The content of THIS FILE IS AUTOGENERATED and should not be manually modified. +# It is maintained by the BCI team and generated by +# https://github.com/SUSE/BCI-dockerfile-generator + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# You can contact the BCI team via https://github.com/SUSE/bci/discussions + +#!UseOBSRepositories + +#!BuildTag: bci/x11:%%xorg_server_ver%%-%RELEASE% +#!BuildTag: bci/x11:%%xorg_server_ver%% +#!BuildTag: bci/x11:21 +#!BuildTag: bci/x11:notaskbar +#!BuildName: bci-x11-21 +#!BuildVersion: 15.7.21 +FROM bci/bci-base:15.7 + +RUN set -euo pipefail; \ + zypper -n install --no-recommends hostname which xinit xhost xorg-x11 xorg-x11-server xrandr icewm-lite xf86-input-evdev xf86-input-libinput xkeyboard-config xinput xorg-x11-essentials xdm; \ + zypper -n clean; \ + rm -rf {/target,}/var/log/{alternatives.log,lastlog,tallylog,zypper.log,zypp/history,YaST2} + +# Define labels according to https://en.opensuse.org/Building_derived_containers +# labelprefix=com.suse.bci.x11 +LABEL org.opencontainers.image.authors="https://github.com/SUSE/bci/discussions" +LABEL org.opencontainers.image.title="SLE BCI X11 Server" +LABEL org.opencontainers.image.description="X11 Server container based on the SLE Base Container Image." +LABEL org.opencontainers.image.version="%%xorg_server_ver%%" +LABEL org.opencontainers.image.url="https://www.suse.com/products/base-container-images/" +LABEL org.opencontainers.image.created="%BUILDTIME%" +LABEL org.opencontainers.image.vendor="SUSE LLC" +LABEL org.opencontainers.image.source="%SOURCEURL%" +LABEL org.opencontainers.image.ref.name="%%xorg_server_ver%%-%RELEASE%" +LABEL org.opensuse.reference="registry.suse.com/bci/x11:%%xorg_server_ver%%-%RELEASE%" +LABEL org.openbuildservice.disturl="%DISTURL%" +LABEL com.suse.supportlevel="techpreview" +LABEL com.suse.eula="sle-bci" +LABEL com.suse.lifecycle-url="https://www.suse.com/lifecycle#suse-linux-enterprise-server-15" +LABEL com.suse.release-stage="beta" +# endlabelprefix +LABEL io.artifacthub.package.readme-url="%SOURCEURL%/README.md" +ENTRYPOINT ["/usr/local/bin/entrypoint.sh"] +# sanity check that the version from the tag is equal to the version of xorg-x11-server that we expect +RUN set -euo pipefail; \ + [ "$(rpm -q --qf '%{version}' xorg-x11-server | \ + cut -d '.' -f -1)" = "21" ] +RUN useradd -m user -u 1000 +COPY preferences /etc/icewm/preferences +COPY xinitrc /etc/X11/xinit/xinitrc +COPY xorg.conf /etc/X11/xorg.conf.d/xorg.conf + +ENV XDG_SESSION_TYPE=x11 + +COPY entrypoint.sh /usr/local/bin/entrypoint.sh +RUN chmod +x /usr/local/bin/entrypoint.sh diff --git a/x11-image/README.md b/x11-image/README.md new file mode 100644 index 000000000..8fd68dde0 --- /dev/null +++ b/x11-image/README.md @@ -0,0 +1,17 @@ +# The SLE BCI X11 Server container image +![Redistributable](https://img.shields.io/badge/Redistributable-Yes-green)![Support Level](https://img.shields.io/badge/Support_Level-techpreview-blue)[![SLSA](https://img.shields.io/badge/SLSA_(v1.0)-Build_L3-Green)](https://documentation.suse.com/sbp/server-linux/html/SBP-SLSA4/) +[![Provenance: Available](https://img.shields.io/badge/Provenance-Available-Green)](https://documentation.suse.com/container/all/html/Container-guide/index.html#container-verify) + +X11 Server container based on the SLE Base Container Image. + +## Licensing + +`SPDX-License-Identifier: MIT` + +This documentation and the build recipe are licensed as MIT. +The container itself contains various software components under various open source licenses listed in the associated +Software Bill of Materials (SBOM). + +This image is a tech preview. Do not use it for production. +Your feedback is welcome. +Please report any issues to the [SUSE Bugzilla](https://bugzilla.suse.com/enter_bug.cgi?product=SUSE%20Linux%20Enterprise%20Base%20Container%20Images). diff --git a/x11-image/_service b/x11-image/_service new file mode 100644 index 000000000..008e3e12f --- /dev/null +++ b/x11-image/_service @@ -0,0 +1,10 @@ + + + + + Dockerfile + %%xorg_server_ver%% + xorg-x11-server + minor + + \ No newline at end of file diff --git a/x11-image/entrypoint.sh b/x11-image/entrypoint.sh new file mode 100644 index 000000000..b16b95808 --- /dev/null +++ b/x11-image/entrypoint.sh @@ -0,0 +1,54 @@ +#!/bin/bash + +# Function to log messages +log() { + echo "[$(date +'%Y-%m-%dT%H:%M:%S%z')] $@" +} + +log "Starting X11 entrypoint script" + +# Trap signals for graceful shutdown +trap 'log "Received SIGTERM, initiating shutdown"; cleanup' SIGTERM +trap 'log "Received SIGINT, initiating shutdown"; cleanup' SIGINT + +# Cleanup function to stop all relevant processes +cleanup() { + log "Cleaning up and stopping processes" + + pkill -SIGTERM Xorg + pkill -SIGTERM icewm-session-lite + + sleep 3 + + log "Cleanup complete, exiting" + exit 0 +} + +# Set default DISPLAY if not set +if [ -z "$DISPLAY" ]; then + log "DISPLAY variable is not set, defaulting to :0" + DISPLAY=:0 +fi + +# Extract display number from DISPLAY variable +DISPLAY_NUM=$(echo $DISPLAY | sed 's/^://') + +# Clean up existing X server lock files and sockets +log "Cleaning up existing X server lock files for display $DISPLAY" +rm -f /tmp/.X${DISPLAY_NUM}-lock /tmp/.X11-unix/X${DISPLAY_NUM} + +if [ $# -gt 0 ]; then + log "Executing custom command: $@" + exec "$@" +else + # Start X server + log "Starting X server on display $DISPLAY" + startx -- "$DISPLAY" & + X_PID=$! + + # Wait for X server process (Xorg) to finish + log "X server (startx) running" + wait $X_PID + + log "X server has exited" +fi diff --git a/x11-image/preferences b/x11-image/preferences new file mode 100644 index 000000000..dd4e095eb --- /dev/null +++ b/x11-image/preferences @@ -0,0 +1,4 @@ +ShowThemesMenu=0 +ShowLogoutMenu=0 +ShowFocusModeMenu=0 +QuickSwitch=0 diff --git a/x11-image/x11-image.changes b/x11-image/x11-image.changes new file mode 100644 index 000000000..9418d89d3 --- /dev/null +++ b/x11-image/x11-image.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Mon Jan 20 10:07:35 UTC 2025 - SUSE Update Bot + +- First version of the X11 Server BCI diff --git a/x11-image/xinitrc b/x11-image/xinitrc new file mode 100644 index 000000000..592485b94 --- /dev/null +++ b/x11-image/xinitrc @@ -0,0 +1,13 @@ +#!/bin/bash +xset -dpms +xset s off +xset s noblank + +[ ! -d "/home/user/xauthority" ] && mkdir -p "/home/user/xauthority" +touch /home/user/xauthority/.xauth +xauth -i -f /home/user/xauthority/.xauth generate :0 . trusted +chown -R user:users /home/user/xauthority + +( [ -f ~/.Xmodmap ] ) && DISPLAY=:0 xmodmap ~/.Xmodmap + +exec icewm-session-lite diff --git a/x11-image/xorg.conf b/x11-image/xorg.conf new file mode 100644 index 000000000..f7baf6207 --- /dev/null +++ b/x11-image/xorg.conf @@ -0,0 +1,43 @@ +Section "Device" + Identifier "modesetting" + Driver "modesetting" + Option "PreferCloneMode" "true" + Option "AccelMethod" "none" +EndSection + +Section "Screen" + Identifier "modesetting" + Device "modesetting" +EndSection + +Section "Device" + Identifier "fbdev" + Driver "fbdev" +EndSection + +Section "Screen" + Identifier "fbdev" + Device "fbdev" +EndSection + +Section "Device" + Identifier "vesa" + Driver "vesa" +EndSection + +Section "Screen" + Identifier "vesa" + Device "vesa" +EndSection + +Section "ServerLayout" + Identifier "Layout" + Screen "modesetting" + Screen "fbdev" + Screen "vesa" +EndSection + +Section "ServerFlags" + Option "DontVTSwitch" "true" + Option "DontZap" "true" +EndSection