jenkins.sh: Add --publish to publish binaries, similar to simtrace2.git

Binaries will be on https://ftp.osmocom.org/binaries/osmo-asf4-dfu/

Change-Id: Idc27a3d7d2bd7cbee1061ce778ace280eff17bf4
master
Harald Welte 3 years ago
parent aec6b1ee85
commit ed363a4a0e
  1. 34
      contrib/jenkins.sh
  2. 3
      gcc/Makefile

@ -1,5 +1,10 @@
#!/bin/sh
if ! [ -x "$(command -v osmo-deps.sh)" ]; then
echo "Error: We need to have scripts/osmo-deps.sh from http://git.osmocom.org/osmo-ci/ in PATH !"
exit 2
fi
set -ex
if [ -z "$MAKE" ]; then
@ -8,10 +13,37 @@ if [ -z "$MAKE" ]; then
exit 1
fi
TOPDIR=`pwd`
publish="$1"
osmo-clean-workspace.sh
verify_value_string_arrays_are_terminated.py $(find . -name "*.[hc]")
cd gcc && $MAKE $PARALLEL_MAKE
cd gcc
$MAKE mrproper
$MAKE $PARALLEL_MAKE
$MAKE $PARALLEL_MAKE BOARD=SYSMOOCTSIM
if [ "x$publish" = "x--publish" ]; then
echo
echo "=============== UPLOAD BUILD =============="
cat > "/build/known_hosts" <<EOF
[rita.osmocom.org]:48 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDDgQ9HntlpWNmh953a2Gc8NysKE4orOatVT1wQkyzhARnfYUerRuwyNr1GqMyBKdSI9amYVBXJIOUFcpV81niA7zQRUs66bpIMkE9/rHxBd81SkorEPOIS84W4vm3SZtuNqa+fADcqe88Hcb0ZdTzjKILuwi19gzrQyME2knHY71EOETe9Yow5RD2hTIpB5ecNxI0LUKDq+Ii8HfBvndPBIr0BWYDugckQ3Bocf+yn/tn2/GZieFEyFpBGF/MnLbAAfUKIdeyFRX7ufaiWWz5yKAfEhtziqdAGZaXNaLG6gkpy3EixOAy6ZXuTAk3b3Y0FUmDjhOHllbPmTOcKMry9
[rita.osmocom.org]:48 ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBPdWn1kEousXuKsZ+qJEZTt/NSeASxCrUfNDW3LWtH+d8Ust7ZuKp/vuyG+5pe5pwpPOgFu7TjN+0lVjYJVXH54=
[rita.osmocom.org]:48 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIK8iivY70EiR5NiGChV39gRLjNpC8lvu1ZdHtdMw2zuX
EOF
SSH_COMMAND="ssh -o 'UserKnownHostsFile=/build/known_hosts' -p 48"
rsync --archive --copy-links --verbose --compress --delete --rsh "$SSH_COMMAND" \
$TOPDIR/gcc/bootloader-sysmooctsim.{bin,elf} \
binaries@rita.osmocom.org:web-files/osmo-asf4-dfu/latest/
rsync --archive --verbose --compress --rsh "$SSH_COMMAND" \
$TOPDIR/gcc/bootloader-*-*.{bin,elf} \
binaries@rita.osmocom.org:web-files/osmo-asf4-dfu/all/
fi
#--exclude $TOPDIR/sysmoOCTSIM/gcc/bootloader-sysmooctsim.bin \
#--exclude $TOPDIR/sysmoOCTSIM/gcc/bootloader-sysmooctsim.elf \
osmo-clean-workspace.sh

@ -257,3 +257,6 @@ clean:
rm -f $(OUTPUT_FILE_NAME).a $(OUTPUT_FILE_NAME).hex $(OUTPUT_FILE_NAME).bin \
$(OUTPUT_FILE_NAME).lss $(OUTPUT_FILE_NAME).eep $(OUTPUT_FILE_NAME).map \
$(OUTPUT_FILE_NAME).srec bootloader-$(BOARD_LC).bin bootloader-$(BOARD_LC).elf
mrproper: clean
rm -f *.o *.d *.a *.elf *.bin *.ihex *.eep *.lss *.map *.srec

Loading…
Cancel
Save