Unverified Commit 4507c318 authored by Birte Kristina Friesel's avatar Birte Kristina Friesel
Browse files

add publish scripts

parent a9c47d78
Loading
Loading
Loading
Loading

scripts/publish-deb

0 → 100755
+26 −0
Original line number Diff line number Diff line
#!/bin/sh

set -e

VERSION="$1"
BASE="libtravel-routing-de-hafas"
OUTFILE="out/${BASE}-perl_${VERSION}-1-1_all.deb"
DEBFILE="/var/www/html/deb/${BASE}-perl_${VERSION}-1_all.deb"

test -n "${VERSION}"

git checkout main

git pull
git submodule update --init

git checkout "${VERSION}"

scripts/makedeb-docker

chmod 644 "${OUTFILE}"
mv "${OUTFILE}" "${DEBFILE}"
ln -s "${BASE}-perl_${VERSION}-1_all.deb" /var/www/html/deb/${BASE}-perl_latest.deb
aptly repo add finalrewind "${DEBFILE}"
aptly publish update stable
chmod -R a+rX ~/.aptly/public

scripts/publish-docker

0 → 100755
+20 −0
Original line number Diff line number Diff line
#!/bin/sh

set -e

VERSION="$1"
test -n "${VERSION}"

git checkout main

git pull
git submodule update --init

git checkout "${VERSION}"

docker build --no-cache -t dbris-m:${VERSION} .
docker build -t dbris-m:latest .
docker tag dbris-m:${VERSION} derfnull/dbris-m:${VERSION}
docker tag dbris-m:latest derfnull/dbris-m:latest
docker push derfnull/dbris-m:${VERSION}
docker push derfnull/dbris-m:latest