Skip to content

Commit

Permalink
renamed to NextCloudPlus
Browse files Browse the repository at this point in the history
  • Loading branch information
nacho committed Apr 20, 2018
1 parent ab913c2 commit 79529c7
Show file tree
Hide file tree
Showing 167 changed files with 238 additions and 280 deletions.
12 changes: 6 additions & 6 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# Batch-build docker container layers for nextcloudpi
# Batch-build docker container layers for NextCloudPlus
#
# 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!
#


nextcloudpi-armhf: nextcloud-armhf
docker build . -f docker-armhf/nextcloudpi/Dockerfile -t ownyourbits/nextcloudpi-armhf:latest --no-cache
nextcloudplus-armhf: nextcloud-armhf
docker build . -f docker-armhf/nextcloudplus/Dockerfile -t ownyourbits/nextcloudplus-armhf:latest --no-cache

nextcloud-armhf: lamp-armhf
docker build . -f docker-armhf/nextcloud/Dockerfile -t ownyourbits/nextcloud-armhf:latest
Expand All @@ -18,8 +18,8 @@ debian-ncp-armhf:
docker build . -f docker-armhf/debian-ncp/Dockerfile -t ownyourbits/debian-ncp-armhf:latest


nextcloudpi-x86: nextcloud-x86
docker build . -f docker/nextcloudpi/Dockerfile -t ownyourbits/nextcloudpi-x86:latest --no-cache
nextcloudplus-x86: nextcloud-x86
docker build . -f docker/nextcloudplus/Dockerfile -t ownyourbits/nextcloudplus-x86:latest --no-cache

nextcloud-x86: lamp-x86
docker build . -f docker/nextcloud/Dockerfile -t ownyourbits/nextcloud-x86:latest
Expand All @@ -31,7 +31,7 @@ debian-ncp-x86:
docker build . -f docker/debian-ncp/Dockerfile -t ownyourbits/debian-ncp-x86:latest

devel:
docker build . -f docker/devel/Dockerfile -t ownyourbits/nextcloudpi-x86:devel
docker build . -f docker/devel/Dockerfile -t ownyourbits/nextcloudplus-x86:devel

# License
#
Expand Down
24 changes: 15 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
# NextCloudPi [![chatroom icon](https://patrolavia.github.io/telegram-badge/chat.png)](https://t.me/NextCloudPi) [![forums icon](https://img.shields.io/badge/help-forums-blue.svg)](https://help.nextcloud.com/c/support/appliances-docker-snappy-vm) [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=N8PJHSEQF4G7Y&lc=US&item_name=Own%20Your%20Bits&item_number=NextCloudPi&no_note=1&no_shipping=1&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donate_LG%2egif%3aNonHosted)
# NextCloudPlus [![chatroom icon](https://patrolavia.github.io/telegram-badge/chat.png)](https://t.me/NextCloudPi) [![forums icon](https://img.shields.io/badge/help-forums-blue.svg)](https://help.nextcloud.com/c/support/appliances-docker-snappy-vm) [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=N8PJHSEQF4G7Y&lc=US&item_name=Own%20Your%20Bits&item_number=NextCloudPi&no_note=1&no_shipping=1&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donate_LG%2egif%3aNonHosted)


![NC Logo](https://ownyourbits.com/wp-content/uploads/2017/11/ncp-square.png)

This is the build code for [NextCloudPi](https://ownyourbits.com/2017/02/13/nextcloud-ready-raspberry-pi-image/).
This is the build code for [NextCloudPlus](https://ownyourbits.com/2017/02/13/nextcloud-ready-raspberry-pi-image/) ( formerly NextCloudPi ).

NextCloudPlus is a ready to use image for Raspberry Pi, odroid HC1 and other boards.

NextCloudPi is a ready to use image for Raspberry Pi.

This code also generates the [NextCloudPi docker images](https://hub.docker.com/r/ownyourbits/nextcloudpi/).
This code also generates the [NextCloudPlus docker images](https://hub.docker.com/r/ownyourbits/nextcloudpi/) for ARM and x86 platforms, and includes an installer for any Debian based system.

## Features

Expand All @@ -18,7 +20,7 @@ This code also generates the [NextCloudPi docker images](https://hub.docker.com/
* MariaDB 10
* Redis memory cache ( NEW 11-12-2017 )
* 4.9 Linux Kernel ( NEW 03-13-2017 )
* nextcloudpi-config for easy setup ( RAM logs, USB drive and more )
* ncp-config for easy setup ( RAM logs, USB drive and more )
* Automatic redirection to HTTPS
* ACPU PHP cache
* PHP Zend OPcache enabled with file cache
Expand All @@ -32,7 +34,7 @@ This code also generates the [NextCloudPi docker images](https://hub.docker.com/
## Extras

* Setup wizard ( NEW 09-27-2017 )
* NextCloudPi Web Panel ( NEW 07-24-2017 )
* NextCloudPlus Web Panel ( NEW 07-24-2017 )
* Wi-Fi ready ( NEW 03-31-2017 )
* Ram logs ( NEW 03-31-2017 )
* Automatic security updates, activated by default. ( NEW 03-21-2017 )
Expand Down Expand Up @@ -73,15 +75,15 @@ Extras can be activated and configured using the web interface at HTTPS port 444
, or from the command line from

```
sudo nextcloudpi-config
sudo ncp-config
```

![NCP-config](https://ownyourbits.com/wp-content/uploads/2017/03/ncp-conf-700x456.jpg)


## How to build

The NextCloudPi SD image is based on Raspbian and is automatically generated using QEMU.
The NextCloudPlus SD image is based on Raspbian and is automatically generated using QEMU.

```
git clone https://github.com/nextcloud/nextcloudpi.git
Expand All @@ -102,10 +104,10 @@ make
```
git clone https://github.com/nextcloud/nextcloudpi.git
cd nextcloudpi
make nextcloudpi-x86
make nextcloudplus-x86
```

NextCloudPi can be installed in any architecture running the latest Debian
NextCloudPlus can be installed in any architecture running the latest Debian

```
# curl -sSL https://raw.githubusercontent.com/nextcloud/nextcloudpi/master/install.sh | bash
Expand All @@ -124,3 +126,7 @@ https://ownyourbits.com/2017/06/08/nextcloudpi-docker-for-raspberry-pi/
https://hub.docker.com/r/ownyourbits/nextcloudpi-x86

https://hub.docker.com/r/ownyourbits/nextcloudpi-armhf

## Contact

You can find us in the [forums](https://help.nextcloud.com/c/support/appliances-docker-snappy-vm) and a [Telegram group](https://t.me/NextCloudPi)
4 changes: 2 additions & 2 deletions armbian.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# arguments: $RELEASE $LINUXFAMILY $BOARD $BUILD_DESKTOP

# This is the image customization script for NextCloudPi on Armbian
# This is the image customization script for NextCloudPlus on Armbian
#
# 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!
Expand Down Expand Up @@ -51,7 +51,7 @@ Main() {

# cleanup all NCP options
source /usr/local/etc/library.sh
cd /usr/local/etc/nextcloudpi-config.d/
cd /usr/local/etc/ncp-config.d/
for script in *.sh; do
cleanup_script $script
done
Expand Down
10 changes: 7 additions & 3 deletions batch.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# Batch creation of NextCloudPi images and containers
# Batch creation of NextCloudPlus images and containers
#
# 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!
Expand All @@ -19,11 +19,15 @@ IP=$1 # First argument is the QEMU Raspbian IP address

# docker x86
docker pull debian:stretch-slim
make nextcloudpi-x86 && {
docker push ownyourbits/nextcloudpi-x86
make nextcloudplus-x86 && {
docker push ownyourbits/nextcloudplus-x86
docker push ownyourbits/nextcloud-x86
docker push ownyourbits/lamp-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 push ownyourbits/nextcloudpi-x86
}

# docker armhf
Expand Down
6 changes: 3 additions & 3 deletions bin/ncp-check-updates
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ VERFILE=/usr/local/etc/ncp-version
LATEST=/var/run/.ncp-latest-version

if ncp-test-updates; then
echo -e "\nNextCloudPi \e[1m$( cat $VERFILE)\e[0m is outdated"
echo -e "update to \e[1m$( cat $LATEST )\e[0m through 'nextcloudpi-config' or type 'sudo ncp-update'"
echo -e "\nNextCloudPlus \e[1m$( cat $VERFILE)\e[0m is outdated"
echo -e "update to \e[1m$( cat $LATEST )\e[0m through 'ncp-config' or type 'sudo ncp-update'"
else
echo -e "\nNextCloudPi \e[1m$( cat $VERFILE)\e[0m is up to date"
echo -e "\nNextCloudPlus \e[1m$( cat $VERFILE)\e[0m is up to date"
fi
12 changes: 6 additions & 6 deletions bin/nextcloudpi-config → bin/ncp-config
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
#!/bin/bash

# NextCloudPi software configuration
# NextCloudPlus software configuration
#
# 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:
# sudo nextcloudpi-config
# sudo ncp-config
#
# More at https://ownyourbits.com/2017/03/13/nextcloudpi-gets-nextcloudpi-config/
#
Expand All @@ -18,16 +18,16 @@ function nextcloud-config()
{
local DIALOG_OK=0
local VERFILE=/var/run/.ncp-latest-version
local BACKTITLE="NextCloudPi configuration ver. "
local CONFDIR=/usr/local/etc/nextcloudpi-config.d/
local BACKTITLE="NextCloudPlus configuration ver. "
local CONFDIR=/usr/local/etc/ncp-config.d/
local DESC

# ask for update if outdated
test -f /usr/local/etc/ncp-changelog && \
local CHANGELOG=$( head -4 /usr/local/etc/ncp-changelog )
ncp-test-updates && \
whiptail --backtitle "$BACKTITLE $( cat /usr/local/etc/ncp-version )" \
--title "NextCloudPi update available" \
--title "NextCloudPlus update available" \
--clear --yesno "Update to $( cat $VERFILE )?\n\n$CHANGELOG" \
15 70
[[ $? -eq $DIALOG_OK ]] && ncp-update
Expand All @@ -45,7 +45,7 @@ function nextcloud-config()
# launch the selection menu
local script
script=$( whiptail --backtitle "$BACKTITLE $( cat /usr/local/etc/ncp-version )" \
--title "NextCloudPi Software Configuration Tool (nextcloudpi-config)" \
--title "NextCloudPlus Software Configuration Tool (ncp-config)" \
--cancel-button Finish --ok-button Select \
--menu "Select program to configure and activate:" 20 105 10 \
"${LIST[@]}" \
Expand Down
8 changes: 4 additions & 4 deletions bin/ncp-diag
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# NextCloudPi diagnostics report
# NextCloudPlus diagnostics report
#
# 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!
Expand All @@ -12,8 +12,8 @@
#

# Distro, NCP version and tag
echo "NextCloudPi version|$( cat /usr/local/etc/ncp-version )"
echo "NextCloudPi image|$( cat /usr/local/etc/ncp-baseimage )"
echo "NextCloudPlus version|$( cat /usr/local/etc/ncp-version )"
echo "NextCloudPlus image|$( cat /usr/local/etc/ncp-baseimage )"
echo "distribution|$( cat /etc/issue )"

# Data
Expand All @@ -23,7 +23,7 @@ test -d "$DATADIR" || DIRINFO=" (doesn't exist)"
USBDEVS="$( lsblk -S -o NAME,TRAN | awk '{ if ( $2 == "usb" ) print $1; }' | tr '\n' ' ' )"
[[ "$USBDEVS" == "" ]] && USBDEVS="none"

echo "automount|$( grep "^ACTIVE_" /usr/local/etc/nextcloudpi-config.d/nc-automount.sh | cut -d'=' -f2 )"
echo "automount|$( grep "^ACTIVE_" /usr/local/etc/ncp-config.d/nc-automount.sh | cut -d'=' -f2 )"
echo "USB devices|$USBDEVS"
echo "datadir|$DATADIR$DIRINFO"
[[ "$DIRINFO" == "" ]] && {
Expand Down
4 changes: 2 additions & 2 deletions bin/ncp-provisioning.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ EOF

CURRENT_THREADS=$( grep "^pm.max_children" /etc/php/7.0/fpm/pool.d/www.conf | awk '{ print $3 }' )

CFG=/usr/local/etc/nextcloudpi-config.d/nc-limits.sh
CFG=/usr/local/etc/ncp-config.d/nc-limits.sh
PHPTHREADS=0
[[ -f "$CFG" ]] && PHPTHREADS=$( grep "^PHPTHREADS_" "$CFG" | cut -d= -f2 )

Expand All @@ -75,7 +75,7 @@ PHPTHREADS=0
}

## Fix permissions on NCP folders. The main reason for this is to make devel docker container work
CONFDIR="/usr/local/etc/nextcloudpi-config.d/"
CONFDIR="/usr/local/etc/ncp-config.d/"
[[ -e $CONFDIR ]] && {
chown -R root:www-data "$CONFDIR"/*
chmod 660 "$CONFDIR"/*
Expand Down
4 changes: 2 additions & 2 deletions bin/ncp-report
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# NextCloudPi diagnostics report
# NextCloudPlus diagnostics report
#
# 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!
Expand Down Expand Up @@ -38,7 +38,7 @@ echo "<--! Paste this in GitHub report -->"

##

open_summary "NextCloudPi diagnostics"
open_summary "NextCloudPlus diagnostics"
bash /usr/local/bin/ncp-diag | column -t -s'|'
close_summary

Expand Down
4 changes: 2 additions & 2 deletions bin/ncp-suggestions
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

#
# NextCloudPi configuration suggestions
# NextCloudPlus configuration suggestions
#
# Copyleft 2018 by Ignacio Nunez Hernanz <nacho _a_t_ ownyourbits _d_o_t_ com>
# GPL licensed (see end of file) * Use at your own risk!
Expand All @@ -14,7 +14,7 @@

OUT="$@"

DNSMASQ_ON="$( grep "^ACTIVE_=" /usr/local/etc/nextcloudpi-config.d/dnsmasq.sh | cut -d'=' -f2 )"
DNSMASQ_ON="$( grep "^ACTIVE_=" /usr/local/etc/ncp-config.d/dnsmasq.sh | cut -d'=' -f2 )"

grep -q "distribution|.*bian GNU/Linux 9" <<<"$OUT" || \
echo -e "You are using an unsupported distro release. Please upgrade to latest Debian/Raspbian"
Expand Down
4 changes: 2 additions & 2 deletions bin/ncp-update
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# update latest NextCloudPi code from github
# update latest NextCloudPlus code from github

{
[ "$(id -u)" -ne 0 ] && { printf "Must be run as root. Try 'sudo $0'\n"; exit 1; }
Expand Down Expand Up @@ -32,7 +32,7 @@
sed '/HEAD ->\|origin/s|\[.*\(tag: v[0-9]\+\.[0-9]\+\.[0-9]\+\).*\]|[\1]|' | \
sed 's|* \[tag: |[|' > /usr/local/etc/ncp-changelog
}
echo -e "NextCloudPi updated to version $VER"
echo -e "NextCloudPlus updated to version $VER"
}

cd /
Expand Down
5 changes: 3 additions & 2 deletions build-SD-odroid.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# Batch creation of NextCloudPi image for the Odroid HC1
# Batch creation of NextCloudPlus image for the Odroid HC1
#
# 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!
Expand All @@ -27,10 +27,11 @@ armbian/compile.sh docker \
RELEASE=stretch\
BUILD_DESKTOP=no\
CLEAN_LEVEL=""\
USE_CCACHE=yes\
NO_APT_CACHER=no

# pack image
IMGNAME="NextCloudPi_$( date "+%m-%d-%y" )_OdroidHC1"
IMGNAME="NextCloudPlus_$( date "+%m-%d-%y" )_OdroidHC1"
IMGFILE="$( ls -1t armbian/output/images/*.img | head -1 )"
pack_image "$IMGFILE" "$IMGNAME.img"

Expand Down
14 changes: 7 additions & 7 deletions build-SD.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

# Batch creation of NextCloudPi image
# Batch creation of NextCloudPlus image
#
# 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!
Expand All @@ -21,10 +21,10 @@ IP=$1 # First argument is the QEMU Raspbian IP address

## BUILDING

NC_INSTALL=etc/nextcloudpi-config.d/nc-nextcloud.sh
NC_CONFIG=etc/nextcloudpi-config.d/nc-init.sh
NC_INSTALL=etc/ncp-config.d/nc-nextcloud.sh
NC_CONFIG=etc/ncp-config.d/nc-init.sh

IMGBASE="NextCloudPi_$( date "+%m-%d-%y" )_base.img"
IMGBASE="NextCloudPlus_$( date "+%m-%d-%y" )_base.img"

export NO_CONFIG=1 # skip interactive configuration

Expand All @@ -35,14 +35,14 @@ download_resize_raspbian_img 1G "$IMGBASE"
NO_HALT_STEP=1 ./installer.sh prepare.sh "$IP" "$IMGBASE"
./installer.sh lamp.sh "$IP" "$( ls -1t *.img | head -1 )"
./installer.sh $NC_INSTALL "$IP" "$( ls -1t *.img | head -1 )"
./installer.sh nextcloudpi.sh "$IP" "$( ls -1t *.img | head -1 )"
./installer.sh nextcloudplus.sh "$IP" "$( ls -1t *.img | head -1 )"
./installer.sh $NC_CONFIG "$IP" "$( ls -1t *.img | head -1 )"
./installer.sh raspbian-cleanup.sh "$IP" "$( ls -1t *.img | head -1 )"

## PACKING

IMGFILE=$( ls -1t *.img | head -1 )
IMGNAME=$( basename "$IMGFILE" _base_prepare_lamp_nc-nextcloud_nextcloudpi_nc-init_raspbian-cleanup.img )
IMGNAME=$( basename "$IMGFILE" _base_prepare_lamp_nc-nextcloud_nextcloudplus_nc-init_raspbian-cleanup.img )

[[ "$IMGNAME" != "" ]] || exit 1

Expand All @@ -65,7 +65,7 @@ upload_ftp "$IMGNAME" || true

## CLEANUP

mkdir -p partial && mv NextCloudPi*.bz2 partial
mkdir -p partial && mv NextCloudPlus*.bz2 partial
rm -f *.img

# License
Expand Down
Loading

0 comments on commit 79529c7

Please sign in to comment.