Continuous integration build option

This commit is contained in:
Bob Mottram 2018-05-07 15:09:59 +01:00
parent 9d17c789ba
commit dfc1272cb3
4 changed files with 15 additions and 2 deletions

View File

@ -74,6 +74,8 @@ IMAGE_NAME='full'
USERNAME="$USER" USERNAME="$USER"
PASSWORD= PASSWORD=
CONTINUOUS_INTEGRATION=
# IP address of the router (gateway) # IP address of the router (gateway)
ROUTER_IP_ADDRESS="192.168.1.254" ROUTER_IP_ADDRESS="192.168.1.254"
@ -378,6 +380,10 @@ do
shift shift
INTERACTIVE="$1" INTERACTIVE="$1"
;; ;;
--ci)
shift
CONTINUOUS_INTEGRATION="$1"
;;
-g|--generic) -g|--generic)
shift shift
GENERIC_IMAGE="$1" GENERIC_IMAGE="$1"
@ -614,6 +620,7 @@ make "$IMAGE_TYPE" \
AMNESIC="$AMNESIC" \ AMNESIC="$AMNESIC" \
SOCIALINSTANCE="$SOCIALINSTANCE" \ SOCIALINSTANCE="$SOCIALINSTANCE" \
EXTERNAL_DRIVE="$EXTERNAL_DRIVE" \ EXTERNAL_DRIVE="$EXTERNAL_DRIVE" \
CONTINUOUS_INTEGRATION="$CONTINUOUS_INTEGRATION" \
LOCAL_NAME="$LOCAL_NAME" LOCAL_NAME="$LOCAL_NAME"
# shellcheck disable=SC2181 # shellcheck disable=SC2181

View File

@ -139,6 +139,8 @@ BMX6_COMMIT='39dd1f2d99ac5a3fa28e92f8173c15039132e181'
BMX7_REPO="https://github.com/bmx-routing/bmx7" BMX7_REPO="https://github.com/bmx-routing/bmx7"
BMX7_COMMIT='0a82c7c10fef44b259b35e77ab33632aa132d219' BMX7_COMMIT='0a82c7c10fef44b259b35e77ab33632aa132d219'
CONTINUOUS_INTEGRATION=
PATH=/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin PATH=/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/bin:/sbin
# Whether to use a SATA drive and if so what its device/partition name is # Whether to use a SATA drive and if so what its device/partition name is

View File

@ -78,6 +78,7 @@ export AMNESIC
export SOCIALINSTANCE export SOCIALINSTANCE
export LOCAL_NAME export LOCAL_NAME
export EXTERNAL_DRIVE export EXTERNAL_DRIVE
export CONTINUOUS_INTEGRATION
# Locate vmdebootstrap program fetched in Makefile # Locate vmdebootstrap program fetched in Makefile
basedir=`pwd` basedir=`pwd`
@ -228,6 +229,7 @@ sed -i "s|SOCIALINSTANCE=.*|SOCIALINSTANCE=\"${SOCIALINSTANCE}\"|g" "$TEMP_CUSTO
sed -i "s|LOCAL_NAME=.*|LOCAL_NAME=\"${LOCAL_NAME}\"|g" "$TEMP_CUSTOMISE3" sed -i "s|LOCAL_NAME=.*|LOCAL_NAME=\"${LOCAL_NAME}\"|g" "$TEMP_CUSTOMISE3"
sed -i "s|EXTERNAL_DRIVE=.*|EXTERNAL_DRIVE=\"${EXTERNAL_DRIVE}\"|g" "$TEMP_CUSTOMISE3" sed -i "s|EXTERNAL_DRIVE=.*|EXTERNAL_DRIVE=\"${EXTERNAL_DRIVE}\"|g" "$TEMP_CUSTOMISE3"
sed -i 's|#!/bin/bash||g' "$TEMP_CUSTOMISE3" sed -i 's|#!/bin/bash||g' "$TEMP_CUSTOMISE3"
sed -i "s|CONTINUOUS_INTEGRATION=.*|CONTINUOUS_INTEGRATION=${CONTINUOUS_INTEGRATION}|g" "$TEMP_CUSTOMISE3"
cat $TEMP_CUSTOMISE2 $TEMP_CUSTOMISE3 > $TEMP_CUSTOMISE4 cat $TEMP_CUSTOMISE2 $TEMP_CUSTOMISE3 > $TEMP_CUSTOMISE4
if [ -f $TEMP_CUSTOMISE ]; then if [ -f $TEMP_CUSTOMISE ]; then

View File

@ -41,8 +41,10 @@ IMAGE = $(NAME).img
ARCHIVE = $(IMAGE).xz ARCHIVE = $(IMAGE).xz
SIGNATURE = $(ARCHIVE).sig SIGNATURE = $(ARCHIVE).sig
OWNER = 1000 OWNER = 1000
XZ = xz --no-warn --verbose --keep --threads=0 -3 if [ ! "$CONTINUOUS_INTEGRATION" ];
SIGN = -gpg --output $(SIGNATURE) --detach-sig $(ARCHIVE) XZ = xz --no-warn --verbose --keep --threads=0 -3
SIGN = -gpg --output $(SIGNATURE) --detach-sig $(ARCHIVE)
fi
# settings for `make test` # settings for `make test`
TEST_SSH_PORT = 2222 TEST_SSH_PORT = 2222