Skip to content

Commit 8eecb66

Browse files
author
SUSE Update Bot
committed
Test build for #1454
1 parent dda642a commit 8eecb66

File tree

7 files changed

+252
-0
lines changed

7 files changed

+252
-0
lines changed

.obs/workflows.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ staging_build:
2525
source_project: home:defolos:BCI:CR:Tumbleweed
2626
source_package: apache-tomcat-9-java-17-image
2727
target_project: home:defolos:BCI:CR:Tumbleweed:Staging
28+
- branch_package:
29+
source_project: home:defolos:BCI:CR:Tumbleweed
30+
source_package: opensuse-base-image
31+
target_project: home:defolos:BCI:CR:Tumbleweed:Staging
2832
- branch_package:
2933
source_project: home:defolos:BCI:CR:Tumbleweed
3034
source_package: blackbox_exporter-image
@@ -252,6 +256,9 @@ refresh_devel_BCI:
252256
- trigger_services:
253257
project: devel:BCI:Tumbleweed
254258
package: apache-tomcat-9-java-17-image
259+
- trigger_services:
260+
project: devel:BCI:Tumbleweed
261+
package: opensuse-base-image
255262
- trigger_services:
256263
project: devel:BCI:Tumbleweed
257264
package: blackbox_exporter-image

opensuse-base-image/LICENSE

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
Permission is hereby granted, free of charge, to any person obtaining a copy
2+
of this software and associated documentation files (the "Software"), to deal
3+
in the Software without restriction, including without limitation the rights
4+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
5+
copies of the Software, and to permit persons to whom the Software is
6+
furnished to do so, subject to the following conditions:
7+
8+
The above copyright notice and this permission notice shall be included in
9+
all copies or substantial portions of the Software.
10+
11+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
13+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
14+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
15+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
17+
SOFTWARE.

opensuse-base-image/README.md

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# SLE BCI Base Container Image
2+
![Redistributable](https://img.shields.io/badge/Redistributable-Yes-green)
3+
4+
## Description
5+
6+
SUSE Linux Enterprise Base Container Images (SLE BCI) provide truly open,
7+
flexible, and secure container images and application development tools. The
8+
images consist of container environments based on SUSE Linux Enterprise and
9+
designed to be a secure base for any containerized workload.
10+
11+
SLE BCI is freely available, re-distributable, and supported across many
12+
different environments. These templates and tools address modern, containerized
13+
application development and CI/CD application containerization. They can be
14+
used immediately by developers and integrators without the “lock-in” imposed by
15+
other offerings.
16+
17+
SLE BCI inherits industry-leading security and compliance from SUSE Linux
18+
within your container build process. The container images are designed to be a
19+
secure base for any application workload. SUSE ensures that compliance
20+
standards are applied consistently and continuously improves security-related
21+
capabilities.
22+
23+
SLE BCI is lightweight and easy to adopt, with the ability to run with any
24+
Linux OS. Avoid lock-in imposed by other vendors and get exactly what you need,
25+
fast. SLE BCI delivers a flexible developer experience that accounts for,
26+
integrates with, and supports language-native tools and workflows.
27+
28+
## Licensing
29+
30+
`SPDX-License-Identifier: MIT`
31+
32+
This documentation and the build recipe are licensed as MIT.
33+
The container itself contains various software components under various open source licenses listed in the associated
34+
Software Bill of Materials (SBOM).
35+
36+
This image is based on [openSUSE Tumbleweed](https://get.opensuse.org/tumbleweed/).

opensuse-base-image/_service

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<services>
2+
<service mode="buildtime" name="kiwi_label_helper"/>
3+
<service mode="buildtime" name="kiwi_metainfo_helper"/>
4+
</services>

opensuse-base-image/config.sh

Lines changed: 91 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,91 @@
1+
#!/bin/bash
2+
# SPDX-License-Identifier: MIT
3+
# SPDX-FileCopyrightText: (c) 2022-2024 SUSE LLC
4+
5+
set -euo pipefail
6+
7+
test -f /.kconfig && . /.kconfig
8+
test -f /.profile && . /.profile
9+
10+
echo "Configure image: [$kiwi_iname]..."
11+
12+
#============================================
13+
# Import repositories' keys if rpm is present
14+
#--------------------------------------------
15+
if command -v rpm > /dev/null; then
16+
suseImportBuildKey
17+
fi
18+
19+
20+
echo "Configure image: [$kiwi_iname]..."
21+
22+
#======================================
23+
# Setup baseproduct link
24+
#--------------------------------------
25+
suseImportBuildKey
26+
27+
28+
# don't have duplicate licenses of the same type
29+
jdupes -1 -L -r /usr/share/licenses
30+
31+
#======================================
32+
# Add repos from control.xml
33+
#--------------------------------------
34+
add-yast-repos
35+
zypper --non-interactive rm -u live-add-yast-repos jdupes
36+
37+
38+
# Not needed, but neither rpm nor libzypp handle rpmlib(X-CheckUnifiedSystemdir) yet
39+
# which would avoid it being installed by filesystem package
40+
rpm -q compat-usrmerge-tools && rpm -e compat-usrmerge-tools
41+
42+
#======================================
43+
# Disable recommends
44+
#--------------------------------------
45+
sed -i 's/.*solver.onlyRequires.*/solver.onlyRequires = true/g' /etc/zypp/zypp.conf
46+
47+
#======================================
48+
# Exclude docs installation
49+
#--------------------------------------
50+
sed -i 's/.*rpm.install.excludedocs.*/rpm.install.excludedocs = yes/g' /etc/zypp/zypp.conf
51+
52+
53+
54+
#======================================
55+
# Remove zypp uuid (bsc#1098535)
56+
#--------------------------------------
57+
rm -f /var/lib/zypp/AnonymousUniqueId
58+
59+
# Remove the entire zypper cache content (not the dir itself, owned by libzypp)
60+
rm -rf /var/cache/zypp/*
61+
62+
# Assign a fixed architecture in zypp.conf, to use the container's arch even if
63+
# the host arch differs (e.g. docker with --platform doesn't affect uname)
64+
arch=$(rpm -q --qf %{arch} glibc)
65+
if [ "$arch" = "i586" ] || [ "$arch" = "i686" ]; then
66+
sed -i "s/^# arch =.*\$/arch = i686/" /etc/zypp/zypp.conf
67+
# Verify that it's applied
68+
grep -q '^arch =' /etc/zypp/zypp.conf
69+
fi#==========================================
70+
# Hack! The go container management tools can't handle sparse files:
71+
# https://github.com/golang/go/issues/13548
72+
# If lastlog doesn't exist, useradd doesn't attempt to reserve space,
73+
# also in derived containers.
74+
#------------------------------------------
75+
rm -f /var/log/lastlog
76+
77+
#======================================
78+
# Remove locale files
79+
#--------------------------------------
80+
(shopt -s globstar; rm -f /usr/share/locale/**/*.mo)
81+
82+
#=======================================
83+
# Clean up after zypper if it is present
84+
#---------------------------------------
85+
if command -v zypper > /dev/null; then
86+
zypper -n clean
87+
fi
88+
89+
rm -rf /var/log/{lastlog,tallylog,zypper.log,zypp/history,YaST2}
90+
91+
exit 0
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
-------------------------------------------------------------------
2+
Thu Jul 25 10:09:04 UTC 2024 - SUSE Update Bot <[email protected]>
3+
4+
- First version of the Base BCI
Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!-- SPDX-License-Identifier: MIT -->
3+
<!--
4+
Copyright (c) 2024 SUSE LLC
5+
6+
All modifications and additions to the file contributed by third parties
7+
remain the property of their copyright owners, unless otherwise agreed
8+
upon.
9+
10+
The content of THIS FILE IS AUTOGENERATED and should not be manually modified.
11+
It is maintained by the BCI team and generated by
12+
https://github.com/SUSE/BCI-dockerfile-generator
13+
14+
Please submit bugfixes or comments via https://bugs.opensuse.org/
15+
You can contact the BCI team via https://github.com/SUSE/bci/discussions
16+
-->
17+
<!-- OBS-AddTag: opensuse/bci/bci-base:%OS_VERSION_ID_SP% opensuse/bci/bci-base:%OS_VERSION_ID_SP%.%RELEASE% -->
18+
<!-- OBS-ExclusiveArch: aarch64 x86_64 ppc64le s390x -->
19+
<!-- OBS-Imagerepo: obsrepositories:/ -->
20+
21+
<image schemaversion="7.4" name="base-image" xmlns:suse_label_helper="com.suse.label_helper">
22+
<description type="system">
23+
<author>openSUSE Project</author>
24+
<contact>https://www.suse.com/</contact>
25+
<specification>openSUSE Tumbleweed BCI %OS_VERSION_NO_DASH% Base Container Image</specification>
26+
</description>
27+
<preferences>
28+
<type image="docker">
29+
<containerconfig
30+
name="opensuse/bci/bci-base"
31+
tag="%OS_VERSION_ID_SP%"
32+
additionaltags="%OS_VERSION_ID_SP%.%RELEASE%"
33+
maintainer="openSUSE (https://www.opensuse.org/)">
34+
<labels>
35+
<suse_label_helper:add_prefix prefix="org.opensuse.bci.base">
36+
<label name="org.opencontainers.image.title" value="openSUSE Tumbleweed BCI %OS_VERSION_NO_DASH% Base"/>
37+
<label name="org.opencontainers.image.description" value="Image for containers based on %OS_PRETTY_NAME%."/>
38+
<label name="org.opencontainers.image.version" value="%OS_VERSION_ID_SP%.%RELEASE%"/>
39+
<label name="org.opencontainers.image.created" value="%BUILDTIME%"/>
40+
<label name="org.opencontainers.image.vendor" value="openSUSE Project"/>
41+
<label name="org.opencontainers.image.source" value="%SOURCEURL%"/>
42+
<label name="org.opencontainers.image.url" value="https://www.opensuse.org"/>
43+
<label name="org.opensuse.reference" value="registry.opensuse.org/opensuse/bci/bci-base:%OS_VERSION_ID_SP%.%RELEASE%"/>
44+
<label name="org.openbuildservice.disturl" value="%DISTURL%"/>
45+
<label name="org.opensuse.release-stage" value="released"/>
46+
<label name="org.opensuse.lifecycle-url" value="https://en.opensuse.org/Lifetime"/>
47+
</suse_label_helper:add_prefix>
48+
<label name="io.artifacthub.package.readme-url" value="https://raw.githubusercontent.com/SUSE/BCI-dockerfile-generator/Tumbleweed/opensuse-base-image/README.md"/>
49+
<label name="io.artifacthub.package.logo-url" value="https://opensource.suse.com/bci/SLE_BCI_logomark_green.svg"/>
50+
</labels>
51+
</containerconfig>
52+
</type>
53+
<version>2024</version>
54+
<packagemanager>zypper</packagemanager>
55+
<rpm-check-signatures>false</rpm-check-signatures>
56+
<rpm-excludedocs>true</rpm-excludedocs>
57+
</preferences>
58+
<repository type="rpm-md">
59+
<source path="obsrepositories:/"/>
60+
</repository>
61+
<packages type="bootstrap">
62+
<package name="aaa_base"/>
63+
<package name="cracklib-dict-small"/>
64+
<package name="filesystem"/>
65+
<package name="glibc-locale-base"/>
66+
<package name="jdupes"/>
67+
<package name="openSUSE-release"/>
68+
<package name="openSUSE-release-appliance-docker"/>
69+
<package name="patterns-base-fips"/>
70+
<package name="patterns-base-minimal_base"/>
71+
<package name="shadow"/>
72+
<package name="zypper"/>
73+
</packages>
74+
<packages type="image">
75+
<package name="bash"/>
76+
<package name="ca-certificates-mozilla"/>
77+
<package name="coreutils"/>
78+
<package name="curl"/>
79+
<package name="gzip"/>
80+
<package name="netcfg"/>
81+
<package name="openssl"/>
82+
<package name="shadow"/>
83+
<package name="tar"/>
84+
<package name="timezone"/>
85+
<package name="gawk"/>
86+
<package name="libcurl-mini4"/>
87+
<package name="live-add-yast-repos"/>
88+
<package name="lsb-release"/>
89+
<package name="openSUSE-build-key"/>
90+
<package name="procps"/>
91+
</packages>
92+
93+
</image>

0 commit comments

Comments
 (0)