updated the images
- added openbao - added my repos to debian and arch
Dieser Commit ist enthalten in:
Ursprung
25301c1bd6
Commit
3eb72c1a14
7 geänderte Dateien mit 77 neuen und 16 gelöschten Zeilen
|
@ -2,8 +2,23 @@
|
||||||
. ./common.sh
|
. ./common.sh
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
arch_install() {
|
||||||
|
buildah run --user 0:0 "$1" curl -Lo /tmp/package.pkg.zst "$2"
|
||||||
|
buildah run --user 0:0 "$1" pacman --noconfirm -U "/tmp/package.pkg.zst"
|
||||||
|
}
|
||||||
|
|
||||||
init_container "archlinux" "docker.io/archlinux"
|
init_container "archlinux" "docker.io/archlinux"
|
||||||
|
buildah run --user 0:0 "archlinux" pacman-key --init
|
||||||
|
buildah run --user 0:0 "archlinux" pacman-key --populate
|
||||||
|
buildah run --user 0:0 "archlinux" tee -a /etc/pacman.conf <<EOF
|
||||||
|
[packete.gitea.sebastian-tobie.de]
|
||||||
|
Server = https://gitea.sebastian-tobie.de/api/packages/packete/arch/packete/$$arch
|
||||||
|
SigLevel = Required
|
||||||
|
EOF
|
||||||
|
curl -s https://gitea.sebastian-tobie.de/api/packages/packete/arch/repository.key | buildah run --user 0:0 "archlinux" pacman-key -a -
|
||||||
|
buildah run --user 0:0 archlinux pacman-key --lsign-key 'packete@noreply.gitea.sebastian-tobie.de'
|
||||||
|
|
||||||
buildah run --user 0:0 "archlinux" pacman --noconfirm -Syu nodejs git base-devel
|
buildah run --user 0:0 "archlinux" pacman --noconfirm -Syu nodejs git base-devel
|
||||||
|
arch_install "$container" "https://github.com/openbao/openbao/releases/download/v${openbao_version}/bao_${openbao_version}_linux_amd64.pkg.tar.zst"
|
||||||
commit "archlinux" "oci:archlinux"
|
commit "archlinux" "oci:archlinux"
|
||||||
du -sh archlinux
|
du -sh archlinux
|
||||||
|
|
|
@ -6,7 +6,7 @@ container="debian_${version}"
|
||||||
|
|
||||||
|
|
||||||
debian_install(){
|
debian_install(){
|
||||||
buildah run --user _apt --workdir /tmp "$1" curl -o package.deb "$2"
|
buildah run --user _apt "$1" curl -Lo /tmp/package.deb "$2"
|
||||||
buildah run --user 0:0 "$1" apt install /tmp/package.deb
|
buildah run --user 0:0 "$1" apt install /tmp/package.deb
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -19,13 +19,14 @@ debian_selection(){
|
||||||
init_container "$container" "docker.io/debian:${version}"
|
init_container "$container" "docker.io/debian:${version}"
|
||||||
buildah config -e DEBIAN_FRONTEND=noninteractive "$container"
|
buildah config -e DEBIAN_FRONTEND=noninteractive "$container"
|
||||||
debian_list=$(mktemp)
|
debian_list=$(mktemp)
|
||||||
sed "s;VERSION;${version};g" repos/debian.list >"$debian_list"
|
sed "s;VERSION;${version};g" repos/debian.sources >"$debian_list"
|
||||||
buildah run --user 0:0 "$container" apt update
|
buildah run --user 0:0 "$container" apt update
|
||||||
buildah run --user 0:0 "$container" apt install -y ca-certificates
|
buildah run --user 0:0 "$container" apt install -y ca-certificates
|
||||||
buildah copy "$container" "$debian_list" /etc/apt/sources.list.d/eigene.list
|
buildah copy "$container" "$debian_list" /etc/apt/sources.list.d/eigene.sources
|
||||||
buildah run --user 0:0 "$container" apt update
|
buildah run --user 0:0 "$container" apt update
|
||||||
debian_selection "$container" selections.txt
|
debian_selection "$container" selections.txt
|
||||||
buildah run --user 0:0 "$container" apt install -y build-essential nodejs git git-buildpackage
|
buildah run --user 0:0 "$container" apt install -y build-essential nodejs git git-buildpackage ca-certificates-st
|
||||||
|
debian_install "$container" "https://github.com/openbao/openbao/releases/download/v${openbao_version}/bao_${openbao_version}_linux_amd64.deb"
|
||||||
commit "$container" "oci:debian:${version}"
|
commit "$container" "oci:debian:${version}"
|
||||||
|
|
||||||
du -sh debian
|
du -sh debian
|
||||||
|
|
|
@ -17,8 +17,12 @@ add_repo(){
|
||||||
buildah run --user 0:0 "$container" dnf config-manager --add-repo "${forgejo}/api/packages/${org}/${group}"
|
buildah run --user 0:0 "$container" dnf config-manager --add-repo "${forgejo}/api/packages/${org}/${group}"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ubi_install(){
|
||||||
|
buildah run "$1" rpm -i "$2"
|
||||||
|
}
|
||||||
|
|
||||||
init_container "$container" "registry.access.redhat.com/ubi${version}:latest"
|
init_container "$container" "registry.access.redhat.com/ubi${version}:latest"
|
||||||
buildah run --user 0:0 "$container" dnf install -y nodejs git rpm-build
|
buildah run --user 0:0 "$container" dnf install -y nodejs git rpm-build
|
||||||
|
ubi_install "$container" "https://github.com/openbao/openbao/releases/download/v${openbao_version}/bao_${openbao_version}_linux_amd64.rpm"
|
||||||
commit "$container" "oci:ubi:$version"
|
commit "$container" "oci:ubi:$version"
|
||||||
du -sh ubi
|
du -sh ubi
|
||||||
|
|
15
cleanup.sh
15
cleanup.sh
|
@ -1,10 +1,13 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
mount=$(buildah mount $1)
|
mount=$(buildah mount $1)
|
||||||
[ -z "$mount" ] && (echo "no mount given" ;exit 1)
|
[ -z "$mount" ] && (echo "no mount given" ;exit 1)
|
||||||
rm -rf "$mount"/usr/share/doc/*
|
rm -rvf "$mount"/usr/share/doc/*
|
||||||
rm -rf "$mount"/usr/share/man/*
|
rm -rvf "$mount"/usr/share/man/*
|
||||||
rm -rf "$mount"/usr/share/locale/*
|
rm -rvf "$mount"/usr/share/locale/*
|
||||||
rm -rf "$mount"/var/lib/apt/lists/*
|
rm -rvf "$mount"/var/lib/apt/lists/*
|
||||||
rm -rf "$mount"/var/cache/*
|
rm -rvf "$mount"/var/cache/*
|
||||||
rm -rf "$mount"/tmp/*
|
rm -rvf "$mount"/tmp/*pod
|
||||||
|
rm -rvf "$mount"/opt/openbao/tls
|
||||||
|
rm -rvf "$mount"/etc/pacman.d/gnupg/{openpgp-revocs.d/,private-keys-v1.d/,pubring.gpg~,S.}*
|
||||||
|
|
||||||
hardlink -potm --reflink=always $mount
|
hardlink -potm --reflink=always $mount
|
||||||
|
|
10
common.sh
10
common.sh
|
@ -1,5 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
empty_dir=$(mktemp -d)
|
empty_dir=$(mktemp -d)
|
||||||
|
openbao_version=2.2.1
|
||||||
|
|
||||||
init_container () {
|
init_container () {
|
||||||
local container_name="$1"
|
local container_name="$1"
|
||||||
|
@ -13,11 +14,10 @@ init_container () {
|
||||||
commit(){
|
commit(){
|
||||||
local container="$1"
|
local container="$1"
|
||||||
buildah config -e - -l - -a - -p - "$container"
|
buildah config -e - -l - -a - -p - "$container"
|
||||||
buildah config -e PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin" "$container"
|
buildah config -u build -e PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin" "$container"
|
||||||
buildah run --user 0:0 mkdir /src
|
buildah run --user 0:0 "$container" mkdir /src
|
||||||
buildah run --user 0:0 useradd -M -u 1000 -U -g 1000 -d /src build
|
buildah run --user 0:0 "$container" useradd -M -u 1000 -U -d /src build
|
||||||
buildah run --user 0:0 chown 1000:1000 /src
|
buildah run --user 0:0 "$container" chown 1000:1000 /src
|
||||||
buildah config -u build
|
|
||||||
buildah unshare ./cleanup.sh "$container"
|
buildah unshare ./cleanup.sh "$container"
|
||||||
buildah commit --rm -f oci --squash "$container" "$2"
|
buildah commit --rm -f oci --squash "$container" "$2"
|
||||||
trap - EXIT
|
trap - EXIT
|
||||||
|
|
|
@ -1 +0,0 @@
|
||||||
#deb https://gitea.sebastian-tobie.de/api/packages/packete/debian VERSION certs
|
|
39
repos/debian.sources
Normale Datei
39
repos/debian.sources
Normale Datei
|
@ -0,0 +1,39 @@
|
||||||
|
Architectures: all
|
||||||
|
Components: main
|
||||||
|
X-Repolib-Name: gitea_sebastian-tobie_de-packete
|
||||||
|
Suites: VERSION
|
||||||
|
Types: deb
|
||||||
|
URIs: https://gitea.sebastian-tobie.de/api/packages/packete/debian
|
||||||
|
Signed-By:
|
||||||
|
-----BEGIN PGP PUBLIC KEY BLOCK-----
|
||||||
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BVBF6PrsxKp6SvZbmOEI+fm/+/j
|
||||||
|
xvfcaiRDaUZRQ113mzBRpMHZtB8m4dw8gnjILNUZlrM72FemcQ9g7wqQFmaYtIw+
|
||||||
|
YmLyQ8Whj28tZWWKnbn8wCfbzKxYpwkaSTncXgdvSEwflUep0a7A3K3X0sSyD3X5
|
||||||
|
htvg3ogRRz2zCrdqH5RWUXrlWcJn9Ap2d4S7QvN32SrNsIW5JivSroZVnTZ+X/M7
|
||||||
|
IcIJlIE7zkJg6gc7orZN4qNKP36omLO01Jq1yq9q+WMulX3FjcwQbspjLKDRahqj
|
||||||
|
Z1fPhFvvFJkXttS+pSQYegu1m8H9nT/4RfxG5QARAQABwsCsBBgBCABgBYJnzgnn
|
||||||
|
CZCeMF8IvS26IzUUAAAAAAAcABBzYWx0QG5vdGF0aW9ucy5vcGVucGdwanMub3Jn
|
||||||
|
Tg9mAaQc9R+kuX0PpC0uHAKbDBYhBJoSBbV7U5zMSy8Kn54wXwi9LbojAACW5QgA
|
||||||
|
heAiJ3S15cumjMGOeS5kMtDKVqNLcFKCqrjv6TCk2jpD4YnW9rVvIfZvb+KGLKPC
|
||||||
|
T4jl4RcxGPEIqIOobEH/rrW4pV82MQxnX0sUsfl6lLAYslYwAF40AGqD0i0+KEKk
|
||||||
|
yj7mNx9Jl8RGrsy21+dKdxzaB+TOxvGrTYhR459ze9aRDiAdYvN9Sqmm2gjiJhfJ
|
||||||
|
gX0tHLaOir66Aya257avkta51MZE3mKZUmsxOqpcmr8OelqSdYjW3L8G+zqy6k74
|
||||||
|
PblvPzL01aBxf/88ss8lkaKMqm7oi2dWyxeaS+HJX+euMsaP+eszXMqHJI4eB3sb
|
||||||
|
7rA/D58QHTTlYhGVQhvjyg==
|
||||||
|
=cjZM
|
||||||
|
-----END PGP PUBLIC KEY BLOCK-----
|
Laden …
Tabelle hinzufügen
In neuem Issue referenzieren