Skip to content

Commit 8ac3607

Browse files
dirkmuellerSUSE Update Bot
authored andcommitted
Test build for #1220
1 parent c60f3cb commit 8ac3607

3 files changed

Lines changed: 87 additions & 26 deletions

File tree

base-image/README.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,33 @@
1-
# The Basalt Project BCI Base container image
1+
# Basalt Project BCI Base Container Image
22
![Redistributable](https://img.shields.io/badge/Redistributable-Yes-green)![Support Level](https://img.shields.io/badge/Support_Level-techpreview-blue)
33
[![SLSA](https://img.shields.io/badge/SLSA_(v0.1)-Level_4-Green)](https://documentation.suse.com/sbp/server-linux/html/SBP-SLSA4/)
44
[![Provenance: Available](https://img.shields.io/badge/Provenance-Available-Green)](https://documentation.suse.com/container/all/html/Container-guide/index.html#container-verify)
55

6-
Base container based on the SUSE Adaptable Linux Platform (ALP).
6+
## Description
7+
8+
SUSE Linux Enterprise Base Container Images (SLE BCI) provide truly open,
9+
flexible, and secure container images and application development tools. The
10+
images consist of container environments based on SUSE Linux Enterprise and
11+
designed to be a secure base for any containerized workload.
12+
13+
SLE BCI is freely available, re-distributable, and supported across many
14+
different environments. These templates and tools address modern, containerized
15+
application development and CI/CD application containerization. They can be
16+
used immediately by developers and integrators without the “lock-in” imposed by
17+
other offerings.
18+
19+
SLE BCI inherits industry-leading security and compliance from SUSE Linux
20+
within your container build process. The container images are designed to be a
21+
secure base for any application workload. SUSE ensures that compliance
22+
standards are applied consistently and continuously improves security-related
23+
capabilities.
24+
25+
SLE BCI is lightweight and easy to adopt, with the ability to run with any
26+
Linux OS. Avoid lock-in imposed by other vendors and get exactly what you need,
27+
fast. SLE BCI delivers a flexible developer experience that accounts for,
28+
integrates with, and supports language-native tools and workflows.
29+
30+
## Usage
731

832
## Licensing
933

base-image/base-image.kiwi

Lines changed: 24 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ You can contact the BCI team via https://github.com/SUSE/bci/discussions
2121
<description type="system">
2222
<author>SUSE LLC</author>
2323
<contact>https://www.suse.com/</contact>
24-
<specification>Basalt Project BCI Base Container Image</specification>
24+
<specification>Basalt Project BCI Base Container Image Container Image</specification>
2525
</description>
2626
<preferences>
2727
<type image="docker">
@@ -32,8 +32,8 @@ You can contact the BCI team via https://github.com/SUSE/bci/discussions
3232
additionaltags="%OS_VERSION_ID_SP%.%RELEASE%,latest">
3333
<labels>
3434
<suse_label_helper:add_prefix prefix="com.suse.basalt.bci.base">
35-
<label name="org.opencontainers.image.title" value="Basalt Project BCI Base"/>
36-
<label name="org.opencontainers.image.description" value="Base container based on the SUSE Adaptable Linux Platform (ALP)."/>
35+
<label name="org.opencontainers.image.title" value="Basalt Project BCI Base Container Image"/>
36+
<label name="org.opencontainers.image.description" value="Base Container Image container based on the SUSE Adaptable Linux Platform (ALP)."/>
3737
<label name="org.opencontainers.image.version" value="%OS_VERSION_ID_SP%.%RELEASE%"/>
3838
<label name="org.opencontainers.image.created" value="%BUILDTIME%"/>
3939
<label name="org.opencontainers.image.vendor" value="SUSE LLC"/>
@@ -47,6 +47,7 @@ You can contact the BCI team via https://github.com/SUSE/bci/discussions
4747
<label name="com.suse.lifecycle-url" value="https://www.suse.com/lifecycle"/>
4848
</suse_label_helper:add_prefix>
4949
<label name="io.artifacthub.package.readme-url" value="%SOURCEURL%/README.md"/>
50+
<label name="io.artifacthub.package.logo-url" value="https://opensource.suse.com/bci/SLE_BCI_logomark_green.svg"/>
5051
</labels>
5152
</containerconfig>
5253
</type>
@@ -60,24 +61,37 @@ You can contact the BCI team via https://github.com/SUSE/bci/discussions
6061
</repository>
6162
<packages type="bootstrap">
6263
<package name="aaa_base"/>
64+
<package name="cracklib-dict-small"/>
65+
<package name="filesystem"/>
66+
<package name="jdupes"/>
67+
<package name="kubic-locale-archive"/>
68+
<package name="patterns-base-fips"/>
69+
<package name="patterns-base-minimal_base"/>
70+
<package name="rpm-ndb"/>
71+
<package name="shadow"/>
72+
<package name="sles-release"/>
73+
<package name="zypper"/>
74+
</packages>
75+
<packages type="image">
6376
<package name="bash"/>
64-
<package name="ca-certificates"/>
6577
<package name="ca-certificates-mozilla"/>
78+
<package name="ca-certificates"/>
79+
<package name="container-suseconnect"/>
6680
<package name="coreutils"/>
67-
<package name="cracklib-dict-small"/>
6881
<package name="curl"/>
69-
<package name="filesystem"/>
82+
<package name="findutils"/>
7083
<package name="glibc-locale-base"/>
7184
<package name="gzip"/>
72-
<package name="jdupes"/>
85+
<package name="lsb-release"/>
7386
<package name="netcfg"/>
74-
<package name="ALP-dummy-release"/>
7587
<package name="openssl"/>
88+
<package name="skelcd-EULA-bci"/>
89+
<package name="sle-module-basesystem-release"/>
90+
<package name="sle-module-server-applications-release"/>
91+
<package name="sle-module-python3-release"/>
7692
<package name="suse-build-key"/>
7793
<package name="tar"/>
7894
<package name="timezone"/>
79-
<package name="zypper"/>
80-
<package name="findutils"/>
8195
</packages>
8296

8397
</image>

base-image/config.sh

Lines changed: 37 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -16,21 +16,29 @@ if command -v rpm > /dev/null; then
1616
suseImportBuildKey
1717
fi
1818

19+
1920
echo "Configure image: [$kiwi_iname]..."
2021

21-
# don't have multiple licenses of the same type
22+
#======================================
23+
# Setup baseproduct link
24+
#--------------------------------------
25+
suseSetupProduct
26+
27+
#======================================
28+
# Import repositories' keys
29+
#--------------------------------------
30+
suseImportBuildKey
31+
32+
33+
# don't have duplicate licenses of the same type
2234
jdupes -1 -L -r /usr/share/licenses
2335

24-
#
2536
zypper --non-interactive rm -u jdupes
2637

2738
# Not needed, but neither rpm nor libzypp handle rpmlib(X-CheckUnifiedSystemdir) yet
2839
# which would avoid it being installed by filesystem package
2940
rpm -e compat-usrmerge-tools
3041

31-
# FIXME: stop hardcoding the url, use some external mechanism once available
32-
zypper -n ar --gpgcheck --enable 'https://updates.suse.com/SUSE/Products/ALP-Dolomite/1.0/$basearch/product/' repo-basalt
33-
3442
#======================================
3543
# Disable recommends
3644
#--------------------------------------
@@ -41,16 +49,25 @@ sed -i 's/.*solver.onlyRequires.*/solver.onlyRequires = true/g' /etc/zypp/zypp.c
4149
#--------------------------------------
4250
sed -i 's/.*rpm.install.excludedocs.*/rpm.install.excludedocs = yes/g' /etc/zypp/zypp.conf
4351

52+
#======================================
53+
# Configure SLE BCI repositories
54+
#--------------------------------------
55+
zypper -n ar --refresh --gpgcheck --priority 100 --enable 'https://updates.suse.com/SUSE/Products/SLE-BCI/$releasever_major-SP$releasever_minor/$basearch/product/' SLE_BCI
56+
zypper -n ar --refresh --gpgcheck --priority 100 --disable 'https://updates.suse.com/SUSE/Products/SLE-BCI/$releasever_major-SP$releasever_minor/$basearch/product_debug/' SLE_BCI_debug
57+
zypper -n ar --refresh --gpgcheck --priority 100 --disable 'https://updates.suse.com/SUSE/Products/SLE-BCI/$releasever_major-SP$releasever_minor/$basearch/product_source/' SLE_BCI_source
58+
4459
#======================================
4560
# Remove locale files
4661
#--------------------------------------
4762
shopt -s globstar
4863
rm -f /usr/share/locale/**/*.mo
4964

65+
#======================================
5066
# Remove zypp uuid (bsc#1098535)
67+
#--------------------------------------
5168
rm -f /var/lib/zypp/AnonymousUniqueId
5269

53-
# Remove various log files. While it's possible to just rm -rf /var/log/*, that
70+
# Remove various log files. Although possible to just rm -rf /var/log/*, that
5471
# would also remove some package owned directories (not %ghost) and some files
5572
# are actually wanted, like lastlog in the !docker case.
5673
# For those wondering about YaST2 here: Kiwi writes /etc/hosts, so the version
@@ -62,14 +79,20 @@ rm -rf /var/log/{zypper.log,zypp/history,YaST2}
6279
# Remove the entire zypper cache content (not the dir itself, owned by libzypp)
6380
rm -rf /var/cache/zypp/*
6481

65-
# Assign a fixed architecture in zypp.conf, to use the container's arch even if
66-
# the host arch differs (e.g. docker with --platform doesn't affect uname)
67-
arch=$(rpm -q --qf %{arch} glibc)
68-
if [ "$arch" = "i586" ] || [ "$arch" = "i686" ]; then
69-
sed -i "s/^# arch =.*\$/arch = i686/" /etc/zypp/zypp.conf
70-
# Verify that it's applied
71-
grep -q '^arch =' /etc/zypp/zypp.conf
72-
fi
82+
#==========================================
83+
# Hack! The go container management tools can't handle sparse files:
84+
# https://github.com/golang/go/issues/13548
85+
# If lastlog doesn't exist, useradd doesn't attempt to reserve space,
86+
# also in derived containers.
87+
#------------------------------------------
88+
rm -f /var/log/lastlog
89+
90+
#======================================
91+
# Remove locale files
92+
#--------------------------------------
93+
find /usr/share/locale -name '*.mo' -delete
94+
95+
exit 0
7396

7497

7598
#=======================================

0 commit comments

Comments
 (0)