diff options
author | nachoparker <nacho@ownyourbits.com> | 2018-05-27 21:58:42 +0300 |
---|---|---|
committer | nachoparker <nacho@ownyourbits.com> | 2018-05-27 22:12:55 +0300 |
commit | 5ea64fdc1209bbec1a3b99afa8105e7622f143d1 (patch) | |
tree | 8f20c29b2d0f02a29076f5bd6ce8d5c039077872 | |
parent | f64df286d37fe483e9ced6c4578a7f68f452f34c (diff) |
build: add bananapi build script
-rwxr-xr-x | batch.sh | 19 | ||||
-rwxr-xr-x | build-SD-bananapi.sh | 44 | ||||
-rwxr-xr-x[-rw-r--r--] | build-SD-odroidHC2.sh (renamed from build-SD-odroid.sh) | 0 | ||||
-rwxr-xr-x[-rw-r--r--] | build-SD-rock64.sh | 0 | ||||
-rwxr-xr-x | build-SD-rpi.sh | 2 |
5 files changed, 56 insertions, 9 deletions
@@ -8,16 +8,22 @@ # Usage: ./batch.sh <DHCP QEMU image IP> # -source buildlib.sh # initializes $IMGNAME +set -e -IP=$1 # First argument is the QEMU Raspbian IP address +IP=${1:-192.168.0.145} # For QEMU automated testing ## BUILDING +source buildlib.sh # initializes $IMGNAME # Raspbian -./build-SD.sh "$IP" +./build-SD-rpi.sh "$IP" -# docker x86 +# Armbian +./build-SD-odroidHC2.sh +./build-SD-rock64.sh +./build-SD-bananapi.sh + +# Docker x86 docker pull debian:stretch-slim make nextcloudplus-x86 && { docker push ownyourbits/nextcloudplus-x86 @@ -26,7 +32,7 @@ make nextcloudplus-x86 && { docker push ownyourbits/debian-ncp-x86 # keep old container updated, at least for a while - docker tag ownyourbits/nextcloudplus-x86 ownyourbits/nextcloudpi-x86 + docker tag ownyourbits/nextcloudplus-x86 ownyourbits/nextcloudpi-x86 docker push ownyourbits/nextcloudpi-x86 } @@ -35,9 +41,6 @@ make nextcloudplus-x86 && { ./installer.sh docker-armhf/docker-env.sh "$IP" raspbian_lite.img # && mv ./installer.sh docker-armhf/build-container.sh "$IP" docker-armhf/raspbian_docker.img -# armbian -./build-SD-odroid.sh - # License # # This script is free software; you can redistribute it and/or modify it diff --git a/build-SD-bananapi.sh b/build-SD-bananapi.sh new file mode 100755 index 00000000..9ec1fe9d --- /dev/null +++ b/build-SD-bananapi.sh @@ -0,0 +1,44 @@ +#!/bin/bash + +# Batch creation of NextCloudPlus image for the Banana Pi +# +# Copyleft 2017 by Ignacio Nunez Hernanz <nacho _a_t_ ownyourbits _d_o_t_ com> +# GPL licensed (see end of file) * Use at your own risk! +# +# Usage: ./build-SD-bananapi.sh <DHCP QEMU image IP> +# + +IMG="NextCloudPi_bananapi_$( date "+%m-%d-%y" ).img" + +set -e + +# get armbian +[[ -d armbian ]] || git clone https://github.com/armbian/build armbian + +# get NCP modifications +mkdir -p armbian/userpatches +wget https://raw.githubusercontent.com/nextcloud/nextcloudpi/master/armbian.sh \ + -O armbian/userpatches/customize-image.sh + +# generate image +armbian/compile.sh docker \ + BOARD=bananapi\ + BRANCH=next\ + KERNEL_ONLY=no\ + KERNEL_CONFIGURE=no\ + RELEASE=stretch\ + BUILD_DESKTOP=no\ + CLEAN_LEVEL=""\ + USE_CCACHE=yes\ + NO_APT_CACHER=no + +# pack image +TAR=output/"$( basename "$IMG" .img ).tar.bz2" +pack_image "$IMG" "$TAR" + +# testing +# TODO + +# uploading +create_torrent "$TAR" +upload_ftp "$( basename "$TAR" .tar.bz2 )" diff --git a/build-SD-odroid.sh b/build-SD-odroidHC2.sh index 5956b167..5956b167 100644..100755 --- a/build-SD-odroid.sh +++ b/build-SD-odroidHC2.sh diff --git a/build-SD-rock64.sh b/build-SD-rock64.sh index a2ddc991..a2ddc991 100644..100755 --- a/build-SD-rock64.sh +++ b/build-SD-rock64.sh diff --git a/build-SD-rpi.sh b/build-SD-rpi.sh index 9fb0155a..09751f73 100755 --- a/build-SD-rpi.sh +++ b/build-SD-rpi.sh @@ -11,7 +11,7 @@ set -e source buildlib.sh -IP=192.168.0.145 # For QEMU automated testing +IP=${1:-192.168.0.145} # For QEMU automated testing SIZE=3G # Raspbian image size #CLEAN=1 # Pass this envvar to clean download cache IMG="NextCloudPi_RPi_$( date "+%m-%d-%y" ).img" |