Debian package repository: take aptly repo vs publish into account
This commit is contained in:
parent
ca5b16a161
commit
078d48730d
2 changed files with 5 additions and 6 deletions
|
@ -41,6 +41,10 @@ deb https://apt.robur.coop/ debian-10 main
|
|||
The `debian-10` can be exchanged with any platform you're building debian
|
||||
packages for.
|
||||
|
||||
Currently, the `dpkg-repo.sh` sets the HOME to `/home/builder` (where aptly
|
||||
expects its configuration), and uses the platform (from builder) as
|
||||
distribution.
|
||||
|
||||
## FreeBSD package repository
|
||||
|
||||
The dependency is FreeBSD's pkg utility.
|
||||
|
|
|
@ -106,12 +106,7 @@ sed -i "" -e "s/Version:.*/Version: ${NEW_VERSION}/g" "${TMP}/DEBIAN/control"
|
|||
|
||||
dpkg-deb --build "${TMP}" "${TMP}"
|
||||
|
||||
REPO_EXISTS=1
|
||||
if ! aptly repo show "${PLATFORM}" > /dev/null 2>&1; then
|
||||
REPO_EXISTS=0
|
||||
fi
|
||||
|
||||
if [ "${REPO_EXISTS}" -eq 0 ]; then
|
||||
aptly repo create --distribution="${PLATFORM}" "${PLATFORM}"
|
||||
fi
|
||||
|
||||
|
@ -119,7 +114,7 @@ aptly repo add "${PLATFORM}" "${TMP}"
|
|||
|
||||
: "${REPO_KEYID:="D5E2DC92617877EDF7D4FD4345EA05FB7E26053D"}"
|
||||
|
||||
if [ "${REPO_EXISTS}" -eq 0 ]; then
|
||||
if ! aptly publish show "${PLATFORM}" > /dev/null 2>&1; then
|
||||
aptly publish repo -gpg-key="${REPO_KEYID}" "${PLATFORM}"
|
||||
else
|
||||
aptly publish update -gpg-key="${REPO_KEYID}" "${PLATFORM}"
|
||||
|
|
Loading…
Reference in a new issue