Add support for bullseye builds

This commit is contained in:
Alexandre Aubin 2021-02-05 01:18:01 +00:00
parent 7b31de62c6
commit c19a5effdc
10 changed files with 36 additions and 15 deletions

View file

@ -1,7 +1,9 @@
#!/bin/bash #!/bin/bash
# For some reason, building chroots for buster from stretch requires libdebian-installer4 0.119 instead of 0.110, c.f. https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=904699 ... installed it by manually downloading and dpkg -i the .deb # For some reason, building chroots for buster from stretch requires libdebian-installer4 0.119 instead of 0.110
readonly DISTRIB=buster # c.f. https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=904699 ... installed it by manually downloading and dpkg -i the .deb
readonly DISTRIB=bullseye
readonly INIT_DIR=$PWD readonly INIT_DIR=$PWD
readonly ARCHS="amd64" readonly ARCHS="amd64"
#readonly ARCHS="i386 armhf armel arm64" #readonly ARCHS="i386 armhf armel arm64"
@ -34,6 +36,10 @@ function build_chroot()
chroot $CHROOT apt dist-upgrade chroot $CHROOT apt dist-upgrade
chroot $CHROOT apt install -y build-essential debhelper cmake wget devscripts git aptitude chroot $CHROOT apt install -y build-essential debhelper cmake wget devscripts git aptitude
# Install build depends for yunohost etc
chroot $CHROOT apt install -y debhelper devscripts dh-python python3-all python3-yaml python3-jinja2 python3-setuptools python3-psutil
chroot $CHROOT apt install -y lua5.1 liblua5.1-dev libidn11-dev libssl-dev txt2man quilt
if [ "$ARCH" == "amd64" ]; if [ "$ARCH" == "amd64" ];
then then
# This is for building yunohost-admin # This is for building yunohost-admin

View file

@ -10,11 +10,10 @@ REPO_URL="forge.yunohost.org"
# Codenames, components and architectures # Codenames, components and architectures
AVAILABLE_CODENAMES="stretch buster" AVAILABLE_CODENAMES="stretch buster bullseye"
AVAILABLE_COMPONENTS="stable testing unstable extra" AVAILABLE_COMPONENTS="stable testing unstable extra"
AVAILABLE_ARCH="amd64 i386 armel armhf arm64" AVAILABLE_ARCH="amd64 i386 armel armhf arm64"
DEFAULT_CODENAME="stretch"
DEFAULT_COMPONENT="unstable" DEFAULT_COMPONENT="unstable"
DEFAULT_ARCH="amd64" DEFAULT_ARCH="amd64"

View file

@ -25,3 +25,17 @@ SignWith: 59A3E6FF
Tracking: all includechanges keepsources Tracking: all includechanges keepsources
Log: logfile Log: logfile
--changes --via=include /home/vinaigrette/scripts/repo/process-include --changes --via=include /home/vinaigrette/scripts/repo/process-include
Origin: YunoHost
Label: YunoHost for Bullseye
Suite: stable
Codename: bullseye
Version: 11.0
Architectures: i386 amd64 armel armhf arm64 source
Components: stable testing unstable extra
AlsoAcceptFor: bullseye-stable bullseye-testing bullseye-unstable stable testing unstable
Description: YunoHost repository for Debian Bullseye
SignWith: 59A3E6FF
Tracking: all includechanges keepsources
Log: logfile
--changes --via=include /home/vinaigrette/scripts/repo/process-include

View file

@ -6,7 +6,7 @@ kill_timeout = 90
source_cmd = /home/vinaigrette/scripts/rebuildd/get-sources ${d} ${p} ${v} source_cmd = /home/vinaigrette/scripts/rebuildd/get-sources ${d} ${p} ${v}
build_cmd = /home/vinaigrette/scripts/rebuildd/build-binaries ${d} ${p} ${v} ${a} build_cmd = /home/vinaigrette/scripts/rebuildd/build-binaries ${d} ${p} ${v} ${a}
post_build_cmd = /home/vinaigrette/scripts/rebuildd/upload-binaries ${d} ${p} ${v} ${a} ${j} post_build_cmd = /home/vinaigrette/scripts/rebuildd/upload-binaries ${d} ${p} ${v} ${a} ${j}
dists = stretch buster dists = stretch buster bullseye
work_dir = /var/cache/rebuildd/build work_dir = /var/cache/rebuildd/build
database_uri = sqlite:///var/lib/rebuildd/rebuildd.db database_uri = sqlite:///var/lib/rebuildd/rebuildd.db
build_more_recent = 1 build_more_recent = 1

View file

@ -4,5 +4,5 @@ PBUILDER_BIN=/usr/sbin/pbuilder
PBUILDER_CACHE_PATH="/var/cache/pbuilder" PBUILDER_CACHE_PATH="/var/cache/pbuilder"
PBUILDER_MIRROR=https://ftp.debian.org/debian PBUILDER_MIRROR=https://ftp.debian.org/debian
ARCHS="amd64 i386 armel armhf arm64" ARCHS="amd64 i386 armel armhf arm64"
DISTS="stretch buster" DISTS="stretch buster bullseye"
ENABLE_BUILDER_MAINT=1 ENABLE_BUILDER_MAINT=1

View file

@ -1,8 +1,7 @@
#!/bin/bash #!/bin/bash
readonly THISSCRIPT=$0 readonly THISSCRIPT=$0
readonly BRANCH_NIGHTLY="dev" readonly DISTRIBS="buster bullseye"
readonly DISTRIBS="buster"
readonly TIMETAG="$(date +%Y%m%d%H%M)" readonly TIMETAG="$(date +%Y%m%d%H%M)"
readonly PACKAGES="moulinette SSOwat yunohost yunohost-admin" readonly PACKAGES="moulinette SSOwat yunohost yunohost-admin"
readonly FORCE="false" readonly FORCE="false"
@ -44,6 +43,9 @@ function build_if_needed()
local DISTRIB=$2 local DISTRIB=$2
local LAST_BUILD_FOR_THIS_PACKAGE=$LAST_BUILDS_CACHE/${DISTRIB}_${PACKAGE} local LAST_BUILD_FOR_THIS_PACKAGE=$LAST_BUILDS_CACHE/${DISTRIB}_${PACKAGE}
BRANCH_NIGHTLY="$DISTRIB"
[[ $DISTRIB == "buster" ]] && BRANCH_NIGHTLY="dev"
cd $GIT_REPOS/$PACKAGE cd $GIT_REPOS/$PACKAGE
git fetch origin >/dev/null 2>/dev/null git fetch origin >/dev/null 2>/dev/null

View file

@ -53,7 +53,6 @@ cat $VINAIGRETTE_HOME/config/sources.list > /etc/apt/sources.list.d/vinaigrette.
sed -i "s/__REPO_URL__/$REPO_URL/g" /etc/nginx/sites-enabled/repo.conf sed -i "s/__REPO_URL__/$REPO_URL/g" /etc/nginx/sites-enabled/repo.conf
sed -i "s/__REPO_URL__/$REPO_URL/g" /etc/apt/sources.list.d/vinaigrette.list sed -i "s/__REPO_URL__/$REPO_URL/g" /etc/apt/sources.list.d/vinaigrette.list
echo "deb https://deb.nodesource.com/node_6.x stretch main" >> /etc/apt/sources.list
echo "127.0.0.1 $REPO_URL" >> /etc/hosts echo "127.0.0.1 $REPO_URL" >> /etc/hosts
service nginx reload service nginx reload

View file

@ -26,7 +26,7 @@ Usage:
$THISSCRIPT <distrib> <branch> <folder> $THISSCRIPT <distrib> <branch> <folder>
Arguments: Arguments:
<distrib> stretch or buster <distrib> stretch or buster or bullseye
<branch> stable, testing, or unstable <branch> stable, testing, or unstable
<folder> the folder in which to build... <folder> the folder in which to build...
EOF EOF
@ -50,7 +50,7 @@ function main()
function validate_arguments() function validate_arguments()
{ {
[[ $DISTRIB =~ ^stretch|buster$ ]] || critical "Invalid distribution $DISTRIB" [[ $DISTRIB =~ ^stretch|buster|bullseye$ ]] || critical "Invalid distribution $DISTRIB"
[[ $BRANCH =~ ^testing|stable|unstable$ ]] || critical "Invalid branch $BRANCH" [[ $BRANCH =~ ^testing|stable|unstable$ ]] || critical "Invalid branch $BRANCH"
[[ ! -z "$FOLDER" ]] || critical "Need a folder in which to build" [[ ! -z "$FOLDER" ]] || critical "Need a folder in which to build"
} }

View file

@ -10,7 +10,7 @@ if ls -d /build/yunohost-admin* >dev/null 2>&1
then then
echo "======================================================" echo "======================================================"
DIST="$(cat /etc/os-release | grep CODENAME= | cut -d = -f 2)" DIST="$(cat /etc/os-release | grep CODENAME= | cut -d = -f 2)"
if [ "$DIST" != "buster" ] if [ "$DIST" == "stretch" ]
then then
/usr/bin/apt-get install git nodejs -y /usr/bin/apt-get install git nodejs -y
echo "========================" echo "========================"
@ -49,7 +49,7 @@ EOF
mkdir /nonexistent mkdir /nonexistent
chown pbuilder:pbuilder /nonexistent chown pbuilder:pbuilder /nonexistent
cd /build/yunohost-admin*/app cd /build/yunohost-admin*/app
if [ "$DIST" != "buster" ] if [ "$DIST" == "stretch" ]
then then
su pbuilder -c "npm install" su pbuilder -c "npm install"
else else

View file

@ -3,9 +3,10 @@
readonly THISSCRIPT=$0 readonly THISSCRIPT=$0
readonly PACKAGE=$1 readonly PACKAGE=$1
readonly BRANCH=$2 readonly BRANCH=$2
readonly DISTRIB="buster" readonly DISTRIB="bullseye"
#readonly DISTRIB="buster"
#readonly DISTRIB="stretch" #readonly DISTRIB="stretch"
readonly DISTRIB_N="10" readonly DISTRIB_N="11"
source /home/vinaigrette/config/config source /home/vinaigrette/config/config
source /home/vinaigrette/scripts/common.sh source /home/vinaigrette/scripts/common.sh