Skip to content
Snippets Groups Projects
Verified Commit cde46716 authored by Morten Linderud's avatar Morten Linderud :surfer:
Browse files

Merge remote-tracking branch 'upstream/merge-requests/52'

* upstream/merge-requests/52:
  fix(test): Prevent pacman 6.1 regression with gpg.conf option
  fix(test): Do not use keyboxd as it prevents the use of pacman-key
  fix(db-functions): Add package signatures back to repo desc files
  feat(test): Use rsop instead of sq for OpenPGP operations
  fix(test/Dockerfile): Add debugedit for the test setup
parents 5566a1e7 f1318037
No related branches found
No related tags found
No related merge requests found
...@@ -734,7 +734,7 @@ arch_repo_modify() { ...@@ -734,7 +734,7 @@ arch_repo_modify() {
local arch=$3 local arch=$3
local pkgs=("${@:4}") local pkgs=("${@:4}")
local dbfile="${FTP_BASE}/${repo}/os/${arch}/${repo}${DBEXT}" local dbfile="${FTP_BASE}/${repo}/os/${arch}/${repo}${DBEXT}"
local repo_action_opts=(--quiet) local repo_action_opts=(--quiet --include-sigs)
if [[ ${action} = remove && ! -f ${dbfile} ]]; then if [[ ${action} = remove && ! -f ${dbfile} ]]; then
error "No database found at '%s'" "$dbfile" error "No database found at '%s'" "$dbfile"
......
FROM docker.io/archlinux/archlinux FROM docker.io/archlinux/archlinux
RUN pacman -Syu --noconfirm --needed \ RUN pacman -Syu --noconfirm --needed \
debugedit \
sudo \ sudo \
fakeroot \ fakeroot \
awk \ awk \
...@@ -15,7 +16,7 @@ RUN pacman -Syu --noconfirm --needed \ ...@@ -15,7 +16,7 @@ RUN pacman -Syu --noconfirm --needed \
git \ git \
parallel \ parallel \
coreutils \ coreutils \
sequoia-sq rsop
RUN pacman-key --init && \ RUN pacman-key --init && \
echo '%wheel ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/wheel && \ echo '%wheel ALL=(ALL) NOPASSWD: ALL' > /etc/sudoers.d/wheel && \
...@@ -57,10 +58,13 @@ RUN pacman-key --init && \ ...@@ -57,10 +58,13 @@ RUN pacman-key --init && \
USER tester USER tester
RUN sq key generate --userid "Bob Tester <tester@localhost>" --output /build/private.key && \ RUN rsop generate-key "Bob Tester <tester@localhost>" > /build/private.tsk && \
sq cert export --keyring /build/private.key | sudo pacman-key -a - && \ rsop extract-cert < /build/private.tsk | sudo pacman-key -a - && \
sudo pacman-key --lsign-key tester@localhost && \ sudo pacman-key --lsign-key tester@localhost && \
gpg --import /build/private.key && \ printf "create ~/.gnupg dir for tester user as otherwise keyboxd is used (which breaks using pacman-key)\n" && \
mkdir -vp /build/.gnupg && \
sudo sh -c 'printf "# this option is only needed due to a regression in pacman 6.1\nlock-never\n" >> /etc/pacman.d/gnupg/gpg.conf' && \
gpg --import /build/private.tsk && \
gpgconf --kill gpg-agent && \ gpgconf --kill gpg-agent && \
gpgconf --kill keyboxd && \ gpgconf --kill keyboxd && \
mkdir -p \ mkdir -p \
......
...@@ -122,7 +122,7 @@ __buildPackage() { ...@@ -122,7 +122,7 @@ __buildPackage() {
done done
for p in ${pkgfiles[@]}; do for p in ${pkgfiles[@]}; do
sq sign --detached --binary --signer-file /build/private.key --output "${p}.sig" "${p}" rsop sign --no-armor /build/private.tsk > "${p}.sig" < "${p}"
if [[ -n ${BUILDDIR} ]]; then if [[ -n ${BUILDDIR} ]]; then
cp -Lv ${p}{,.sig} ${cache}/ cp -Lv ${p}{,.sig} ${cache}/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment