Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: haiku/infrastructure
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: f4c60f0ef38e
Choose a base ref
...
head repository: haiku/infrastructure
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: c41de24aa79b
Choose a head ref
  • 3 commits
  • 2 files changed
  • 1 contributor

Commits on Oct 28, 2021

  1. Copy the full SHA
    87ede3b View commit details
  2. Copy the full SHA
    2cc0024 View commit details
  3. Copy the full SHA
    c41de24 View commit details
Showing with 21 additions and 17 deletions.
  1. +12 −8 containers/forklift/forklift.sh
  2. +9 −9 containers/loadingdock/entry.sh
20 changes: 12 additions & 8 deletions containers/forklift/forklift.sh
Original file line number Diff line number Diff line change
@@ -9,22 +9,26 @@ export OUTGOING=/haikuports-data/build-packages/master/packages
# build-packages
while true; do
for i in arm arm64 m68k ppc sparc riscv64 x86 x86_64; do
if [ ! -d "${INCOMING}/build-packages/${i})" ]; then
echo "$(date) - build-packages/$i missing!"
ARCH_PATH="${INCOMING}/build-packages/${i}"
if [ ! -d "${ARCH_PATH}" ]; then
echo "$(date) - ${ARCH_PATH} missing!"
continue;
fi
if [ ! "$(ls -A ${INCOMING}/build-packages/${i})" ]; then
if [ ! "$(ls -A ${ARCH_PATH})" ]; then
continue;
else
echo "$(date) - new build-packages inbound for $i..."
ls -la ${INCOMING}/build-packages/${i}
ls -la ${ARCH_PATH}
# clobber architecture packages
find ${INCOMING}/build-packages/${i} -name "*${i}.hpkg" -mmin +30 -exec mv -v -f {} ${OUTGOING}/ \;
echo "$(date) - moving $i packages to build-packages repo..."
find ${ARCH_PATH} -name "*-${i}.hpkg" -mmin +30 -exec mv -v -f {} ${OUTGOING}/ \;
# don't clobber source or any packages since it could break other architecture repos?
find ${INCOMING}/build-packages/${i} -name "*source.hpkg" -mmin +30 -exec mv -v -n {} ${OUTGOING}/ \;
find ${INCOMING}/build-packages/${i} -name "*any.hpkg" -mmin +30 -exec mv -v -n {} ${OUTGOING}/ \;
echo "$(date) - moving $i source/any packages to build-packages repo..."
find ${ARCH_PATH} -name "*-source.hpkg" -mmin +30 -exec mv -v -n {} ${OUTGOING}/ \;
find ${ARCH_PATH} -name "*-any.hpkg" -mmin +30 -exec mv -v -n {} ${OUTGOING}/ \;
# cleanup
find ${INCOMING}/build-packages/${i} -name "*" -mmin +60 -exec rm -vf {} \;
echo "$(date) - cleaning up anything we don't need / want..."
find ${ARCH_PATH} -name "*" -mmin +60 -exec rm -vf {} \;
fi
done
sleep 5m
18 changes: 9 additions & 9 deletions containers/loadingdock/entry.sh
Original file line number Diff line number Diff line change
@@ -20,13 +20,13 @@ git clone /gerrit/git/All-Users.git
cd All-Users

# Collect ssh public keys from users in gerrit
for i in ${GERRIT_UIDS}; do
git fetch origin refs/users/${i:(-2)}/${i}:${i}
git checkout ${i}
for id in ${GERRIT_UIDS}; do
git fetch origin refs/users/${id:(-2)}/${id}:${id}
git checkout ${id}
if [ -f authorized_keys ]; then
cat authorized_keys >> /etc/authorized_keys/submit
else
echo "No authorized_keys for UID $i!"
echo "No authorized_keys for UID $id!"
fi
done
chown -R submit:users /etc/authorized_keys/submit
@@ -36,14 +36,14 @@ chmod 600 /etc/authorized_keys/submit
mkdir -p /sftp/build-packages
chmod 750 /sftp/build-packages

chown -R submit:users /sftp/build-packages/${i}
for i in arm arm64 m68k ppc sparc riscv64 x86 x86_64; do
chown -R submit:users /sftp/build-packages/${arch}
for arch in arm arm64 m68k ppc sparc riscv64 x86 x86_64; do
echo "Upload new packages to the relevant directory!" > /sftp/README
echo "" >> /sftp/README
echo " * build-packages - New build-packages (locally build, maybe unbootstraped)" >> /sftp/README
mkdir -p /sftp/build-packages/${i}
chown -R submit:users /sftp/build-packages/${i}
chmod 770 /sftp/build-packages/${i}
mkdir -p /sftp/build-packages/${arch}
chown -R submit:users /sftp/build-packages/${arch}
chmod 770 /sftp/build-packages/${arch}
done

chown root:root /sftp /sftp/README