2022-04-27 14:18:24 +02:00
|
|
|
#!/bin/sh
|
|
|
|
# SPDX-License-Identifier: MIT
|
2023-02-21 09:48:12 +01:00
|
|
|
# SPDX-FileCopyrightText: (c) 2022-2023 SUSE LLC
|
2022-04-27 14:18:24 +02:00
|
|
|
|
|
|
|
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
|
|
|
|
|
2023-05-04 15:19:59 +02:00
|
|
|
|
2022-04-27 14:18:24 +02:00
|
|
|
sed -i 's|/bin/bash|/bin/sh|' /etc/passwd
|
2023-05-04 15:19:59 +02:00
|
|
|
# Will be recreated by the next rpm(1) run as root user
|
|
|
|
rm -v /usr/lib/sysimage/rpm/Index.db
|
|
|
|
|
2022-04-27 14:18:24 +02:00
|
|
|
|
2022-05-02 09:27:18 +02:00
|
|
|
#=======================================
|
|
|
|
# Clean up after zypper if it is present
|
|
|
|
#---------------------------------------
|
|
|
|
if command -v zypper > /dev/null; then
|
|
|
|
zypper -n clean
|
|
|
|
fi
|
|
|
|
|
|
|
|
rm -rf /var/log/zypp
|
|
|
|
|
2022-04-27 14:18:24 +02:00
|
|
|
exit 0
|