From 4cf7830fd80df314603a309e05ab297b2e69aee1 Mon Sep 17 00:00:00 2001 From: Sebastian Silva Date: Mon, 17 Sep 2018 02:05:31 -0500 Subject: [PATCH 01/12] Add rpicam software --- builder/chroot-script.sh | 14 ++++++++++++++ builder/files/etc/rc.local | 14 ++++++++++++++ builder/files/etc/rpicam_config.txt | 8 ++++++++ 3 files changed, 36 insertions(+) create mode 100755 builder/files/etc/rc.local create mode 100644 builder/files/etc/rpicam_config.txt diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index f9ac33b..fe77ab4 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -147,6 +147,12 @@ apt-get -o Dpkg::Options::=--force-confdef \ pi-bluetooth \ lsb-release \ gettext \ + unzip \ + zip \ + libav-tools \ + gstreamer1.0-tools \ + motion \ + gpac \ cloud-init @@ -209,6 +215,14 @@ echo "Installing rpi-serial-console script" wget -q https://raw.githubusercontent.com/lurch/rpi-serial-console/master/rpi-serial-console -O usr/local/bin/rpi-serial-console chmod +x usr/local/bin/rpi-serial-console +echo "Installing RPi Cam Web Interface" +wget -q https://github.com/silvanmelchior/RPi_Cam_Web_Interface/archive/master.zip -O /tmp/rpicam.zip +cd /tmp/ +unzip rpicam.zip +cd RPi_Cam_Web_Interface-master +cp /etc/rpicam_config.txt config.txt +bash ./install.sh q + # fix eth0 interface name ln -s /dev/null /etc/systemd/network/99-default.link diff --git a/builder/files/etc/rc.local b/builder/files/etc/rc.local new file mode 100755 index 0000000..65634df --- /dev/null +++ b/builder/files/etc/rc.local @@ -0,0 +1,14 @@ +#!/bin/sh -e +# +# rc.local +# +# This script is executed at the end of each multiuser runlevel. +# Make sure that the script will "exit 0" on success or any other +# value on error. +# +# In order to enable or disable this script just change the execution +# bits. +# +# By default this script does nothing. + +exit 0 diff --git a/builder/files/etc/rpicam_config.txt b/builder/files/etc/rpicam_config.txt new file mode 100644 index 0000000..325c3f4 --- /dev/null +++ b/builder/files/etc/rpicam_config.txt @@ -0,0 +1,8 @@ +rpicamdir="cam" +webserver="" +webport="80" +user="" +webpasswd="" +autostart="yes" +jpglink="no" +phpversion="7" From 73dbdd9868ba635b2569520148a580d3bd58b8a6 Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 22 Oct 2018 18:27:02 -0400 Subject: [PATCH 02/12] Install infragram --- builder/build.sh | 2 +- builder/chroot-script.sh | 15 +++++++++++++++ builder/files/var/www/index.html | 3 +++ versions.config | 4 ++-- 4 files changed, 21 insertions(+), 3 deletions(-) diff --git a/builder/build.sh b/builder/build.sh index eaf17f2..aee6799 100755 --- a/builder/build.sh +++ b/builder/build.sh @@ -84,7 +84,7 @@ ls -alh /image_with_kernel_*.tar.gz # download the ready-made raw image for the RPi if [ ! -f "${BUILD_RESULT_PATH}/${RAW_IMAGE}.zip" ]; then - wget -q -O "${BUILD_RESULT_PATH}/${RAW_IMAGE}.zip" "https://github.com/hypriot/image-builder-raw/releases/download/${RAW_IMAGE_VERSION}/${RAW_IMAGE}.zip" + wget -q -O "${BUILD_RESULT_PATH}/${RAW_IMAGE}.zip" "https://jenkins.laboratoriopublico.org/job/image-builder-raw/ws/${RAW_IMAGE}.zip" fi # verify checksum of the ready-made raw image diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index fe77ab4..19fd25d 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -211,6 +211,21 @@ lighttpd-enable-mod fastcgi-php systemctl disable dhcpcd systemctl disable hciuart +echo "Installing infragram" + +# install npm/node: +curl -o node-v9.7.1-linux-armv6l.tar.gz https://nodejs.org/dist/v9.7.1/node-v9.7.1-linux-armv6l.tar.gz +tar -xzf node-v9.7.1-linux-armv6l.tar.gz +sudo cp -r node-v9.7.1-linux-armv6l/* /usr/local/ +sudo apt-get install git + +# install infragram in the web public folder: +cd /var/www/ +git clone https://github.com/publiclab/infragram.git +cd infragram +npm install +cd / + echo "Installing rpi-serial-console script" wget -q https://raw.githubusercontent.com/lurch/rpi-serial-console/master/rpi-serial-console -O usr/local/bin/rpi-serial-console chmod +x usr/local/bin/rpi-serial-console diff --git a/builder/files/var/www/index.html b/builder/files/var/www/index.html index 2072df6..18f4148 100644 --- a/builder/files/var/www/index.html +++ b/builder/files/var/www/index.html @@ -26,5 +26,8 @@

Public Lab Pi Camera Kit

If you're seeing this in a pop-up, close it and open http://pi.local in a browser.

On Android devices, you may have to turn off cellular data to use this in a browser.

+

Access Infragram software

+

Access the camera

+ diff --git a/versions.config b/versions.config index f7bb136..d1e5bfc 100644 --- a/versions.config +++ b/versions.config @@ -4,8 +4,8 @@ ROOTFS_TAR_CHECKSUM="d1e7e6d48a25b4a206c5df99ecb8815388ec6945e4f97e78413d5a80778 # name of the ready made raw image for RPi RAW_IMAGE="rpi-raw.img" -RAW_IMAGE_VERSION="v0.2.2" -RAW_IMAGE_CHECKSUM="2fbeb13b7b0f2308dbd0d82780b54c33003ad43d145ff08498b25fb8bbe1c2c6" +RAW_IMAGE_VERSION="master" +RAW_IMAGE_CHECKSUM="e32c0b9f3cdb9c60bad97a724103fc1283cdc135848e6142d588cd96fac1d6a8" # specific versions of kernel/firmware and docker tools export KERNEL_BUILD="20180422-141901" From 73c873d01062b18b66ab2afe76072eb88dea7364 Mon Sep 17 00:00:00 2001 From: jywarren Date: Thu, 1 Nov 2018 11:29:32 -0400 Subject: [PATCH 03/12] add image sequencer --- builder/chroot-script.sh | 11 ++++++++++- builder/files/var/www/index.html | 1 + 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index 19fd25d..e292997 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -219,13 +219,22 @@ tar -xzf node-v9.7.1-linux-armv6l.tar.gz sudo cp -r node-v9.7.1-linux-armv6l/* /usr/local/ sudo apt-get install git -# install infragram in the web public folder: cd /var/www/ + +# install infragram in the web public folder: git clone https://github.com/publiclab/infragram.git cd infragram npm install cd / +echo "Installing image-sequencer" +# install image-sequencer in the web public folder: +git clone https://github.com/publiclab/image-sequencer.git +cd image-sequencer +npm install + +cd / + echo "Installing rpi-serial-console script" wget -q https://raw.githubusercontent.com/lurch/rpi-serial-console/master/rpi-serial-console -O usr/local/bin/rpi-serial-console chmod +x usr/local/bin/rpi-serial-console diff --git a/builder/files/var/www/index.html b/builder/files/var/www/index.html index 18f4148..5a8152e 100644 --- a/builder/files/var/www/index.html +++ b/builder/files/var/www/index.html @@ -28,6 +28,7 @@

Public Lab Pi Camera Kit

Access Infragram software

Access the camera

+

Access Image Sequencer software

From f2d06f038c9ab97205dada727aaaf3e2b2f03300 Mon Sep 17 00:00:00 2001 From: jywarren Date: Mon, 5 Nov 2018 12:25:20 -0500 Subject: [PATCH 04/12] added buttons and new version of image sequencer --- builder/files/var/www/index.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/builder/files/var/www/index.html b/builder/files/var/www/index.html index 5a8152e..f58544c 100644 --- a/builder/files/var/www/index.html +++ b/builder/files/var/www/index.html @@ -26,9 +26,9 @@

Public Lab Pi Camera Kit

If you're seeing this in a pop-up, close it and open http://pi.local in a browser.

On Android devices, you may have to turn off cellular data to use this in a browser.

-

Access Infragram software

-

Access the camera

-

Access Image Sequencer software

+

Access Infragram software

+

Access the camera

+

Access Image Sequencer software

From a1e97fce632476ba2dd89eae4c2bc03d85eab831 Mon Sep 17 00:00:00 2001 From: jywarren Date: Mon, 5 Nov 2018 12:38:29 -0500 Subject: [PATCH 05/12] path fixx --- builder/chroot-script.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index e292997..a069607 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -225,7 +225,7 @@ cd /var/www/ git clone https://github.com/publiclab/infragram.git cd infragram npm install -cd / +cd /var/www/ echo "Installing image-sequencer" # install image-sequencer in the web public folder: From 8e0cb8dd9aec514d0cfe155e159e9f6db299fb6b Mon Sep 17 00:00:00 2001 From: jywarren Date: Mon, 5 Nov 2018 14:37:46 -0500 Subject: [PATCH 06/12] added comment and bump infragram version --- builder/chroot-script.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index a069607..0fc4c63 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -222,6 +222,7 @@ sudo apt-get install git cd /var/www/ # install infragram in the web public folder: +echo "Installing infragram" git clone https://github.com/publiclab/infragram.git cd infragram npm install From 2537cbfe311df55a3679dc3a1516867096c9e76b Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 5 Nov 2018 18:23:06 -0500 Subject: [PATCH 07/12] Revert "added comment and bump infragram version" This reverts commit 8e0cb8dd9aec514d0cfe155e159e9f6db299fb6b. --- builder/chroot-script.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index 0fc4c63..a069607 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -222,7 +222,6 @@ sudo apt-get install git cd /var/www/ # install infragram in the web public folder: -echo "Installing infragram" git clone https://github.com/publiclab/infragram.git cd infragram npm install From 0221b15af7971b1147455a488d7ca81e81e3eca9 Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 5 Nov 2018 18:23:06 -0500 Subject: [PATCH 08/12] Revert "path fixx" This reverts commit a1e97fce632476ba2dd89eae4c2bc03d85eab831. --- builder/chroot-script.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index a069607..e292997 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -225,7 +225,7 @@ cd /var/www/ git clone https://github.com/publiclab/infragram.git cd infragram npm install -cd /var/www/ +cd / echo "Installing image-sequencer" # install image-sequencer in the web public folder: From c082a6038aee36c1779588de70398ddaa2657846 Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 5 Nov 2018 18:23:06 -0500 Subject: [PATCH 09/12] Revert "added buttons and new version of image sequencer" This reverts commit f2d06f038c9ab97205dada727aaaf3e2b2f03300. --- builder/files/var/www/index.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/builder/files/var/www/index.html b/builder/files/var/www/index.html index f58544c..5a8152e 100644 --- a/builder/files/var/www/index.html +++ b/builder/files/var/www/index.html @@ -26,9 +26,9 @@

Public Lab Pi Camera Kit

If you're seeing this in a pop-up, close it and open http://pi.local in a browser.

On Android devices, you may have to turn off cellular data to use this in a browser.

-

Access Infragram software

-

Access the camera

-

Access Image Sequencer software

+

Access Infragram software

+

Access the camera

+

Access Image Sequencer software

From 54ea680da8e1cb5fdbe05ee0427d867540279a1b Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 5 Nov 2018 18:23:06 -0500 Subject: [PATCH 10/12] Revert "add image sequencer" This reverts commit 73c873d01062b18b66ab2afe76072eb88dea7364. --- builder/chroot-script.sh | 11 +---------- builder/files/var/www/index.html | 1 - 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index e292997..19fd25d 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -219,22 +219,13 @@ tar -xzf node-v9.7.1-linux-armv6l.tar.gz sudo cp -r node-v9.7.1-linux-armv6l/* /usr/local/ sudo apt-get install git -cd /var/www/ - # install infragram in the web public folder: +cd /var/www/ git clone https://github.com/publiclab/infragram.git cd infragram npm install cd / -echo "Installing image-sequencer" -# install image-sequencer in the web public folder: -git clone https://github.com/publiclab/image-sequencer.git -cd image-sequencer -npm install - -cd / - echo "Installing rpi-serial-console script" wget -q https://raw.githubusercontent.com/lurch/rpi-serial-console/master/rpi-serial-console -O usr/local/bin/rpi-serial-console chmod +x usr/local/bin/rpi-serial-console diff --git a/builder/files/var/www/index.html b/builder/files/var/www/index.html index 5a8152e..18f4148 100644 --- a/builder/files/var/www/index.html +++ b/builder/files/var/www/index.html @@ -28,7 +28,6 @@

Public Lab Pi Camera Kit

Access Infragram software

Access the camera

-

Access Image Sequencer software

From 3271f97cd3501a8abc0a71f8bffac53cbfe3af9d Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 5 Nov 2018 18:23:06 -0500 Subject: [PATCH 11/12] Revert "Install infragram" This reverts commit 73dbdd9868ba635b2569520148a580d3bd58b8a6. --- builder/build.sh | 2 +- builder/chroot-script.sh | 15 --------------- builder/files/var/www/index.html | 3 --- versions.config | 4 ++-- 4 files changed, 3 insertions(+), 21 deletions(-) diff --git a/builder/build.sh b/builder/build.sh index aee6799..eaf17f2 100755 --- a/builder/build.sh +++ b/builder/build.sh @@ -84,7 +84,7 @@ ls -alh /image_with_kernel_*.tar.gz # download the ready-made raw image for the RPi if [ ! -f "${BUILD_RESULT_PATH}/${RAW_IMAGE}.zip" ]; then - wget -q -O "${BUILD_RESULT_PATH}/${RAW_IMAGE}.zip" "https://jenkins.laboratoriopublico.org/job/image-builder-raw/ws/${RAW_IMAGE}.zip" + wget -q -O "${BUILD_RESULT_PATH}/${RAW_IMAGE}.zip" "https://github.com/hypriot/image-builder-raw/releases/download/${RAW_IMAGE_VERSION}/${RAW_IMAGE}.zip" fi # verify checksum of the ready-made raw image diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index 19fd25d..fe77ab4 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -211,21 +211,6 @@ lighttpd-enable-mod fastcgi-php systemctl disable dhcpcd systemctl disable hciuart -echo "Installing infragram" - -# install npm/node: -curl -o node-v9.7.1-linux-armv6l.tar.gz https://nodejs.org/dist/v9.7.1/node-v9.7.1-linux-armv6l.tar.gz -tar -xzf node-v9.7.1-linux-armv6l.tar.gz -sudo cp -r node-v9.7.1-linux-armv6l/* /usr/local/ -sudo apt-get install git - -# install infragram in the web public folder: -cd /var/www/ -git clone https://github.com/publiclab/infragram.git -cd infragram -npm install -cd / - echo "Installing rpi-serial-console script" wget -q https://raw.githubusercontent.com/lurch/rpi-serial-console/master/rpi-serial-console -O usr/local/bin/rpi-serial-console chmod +x usr/local/bin/rpi-serial-console diff --git a/builder/files/var/www/index.html b/builder/files/var/www/index.html index 18f4148..2072df6 100644 --- a/builder/files/var/www/index.html +++ b/builder/files/var/www/index.html @@ -26,8 +26,5 @@

Public Lab Pi Camera Kit

If you're seeing this in a pop-up, close it and open http://pi.local in a browser.

On Android devices, you may have to turn off cellular data to use this in a browser.

-

Access Infragram software

-

Access the camera

- diff --git a/versions.config b/versions.config index d1e5bfc..f7bb136 100644 --- a/versions.config +++ b/versions.config @@ -4,8 +4,8 @@ ROOTFS_TAR_CHECKSUM="d1e7e6d48a25b4a206c5df99ecb8815388ec6945e4f97e78413d5a80778 # name of the ready made raw image for RPi RAW_IMAGE="rpi-raw.img" -RAW_IMAGE_VERSION="master" -RAW_IMAGE_CHECKSUM="e32c0b9f3cdb9c60bad97a724103fc1283cdc135848e6142d588cd96fac1d6a8" +RAW_IMAGE_VERSION="v0.2.2" +RAW_IMAGE_CHECKSUM="2fbeb13b7b0f2308dbd0d82780b54c33003ad43d145ff08498b25fb8bbe1c2c6" # specific versions of kernel/firmware and docker tools export KERNEL_BUILD="20180422-141901" From 8a773b0f064333e931784311de41a45054caea1e Mon Sep 17 00:00:00 2001 From: Jeffrey Warren Date: Mon, 5 Nov 2018 18:23:06 -0500 Subject: [PATCH 12/12] Revert "Add rpicam software" This reverts commit 4cf7830fd80df314603a309e05ab297b2e69aee1. --- builder/chroot-script.sh | 14 -------------- builder/files/etc/rc.local | 14 -------------- builder/files/etc/rpicam_config.txt | 8 -------- 3 files changed, 36 deletions(-) delete mode 100755 builder/files/etc/rc.local delete mode 100644 builder/files/etc/rpicam_config.txt diff --git a/builder/chroot-script.sh b/builder/chroot-script.sh index fe77ab4..f9ac33b 100644 --- a/builder/chroot-script.sh +++ b/builder/chroot-script.sh @@ -147,12 +147,6 @@ apt-get -o Dpkg::Options::=--force-confdef \ pi-bluetooth \ lsb-release \ gettext \ - unzip \ - zip \ - libav-tools \ - gstreamer1.0-tools \ - motion \ - gpac \ cloud-init @@ -215,14 +209,6 @@ echo "Installing rpi-serial-console script" wget -q https://raw.githubusercontent.com/lurch/rpi-serial-console/master/rpi-serial-console -O usr/local/bin/rpi-serial-console chmod +x usr/local/bin/rpi-serial-console -echo "Installing RPi Cam Web Interface" -wget -q https://github.com/silvanmelchior/RPi_Cam_Web_Interface/archive/master.zip -O /tmp/rpicam.zip -cd /tmp/ -unzip rpicam.zip -cd RPi_Cam_Web_Interface-master -cp /etc/rpicam_config.txt config.txt -bash ./install.sh q - # fix eth0 interface name ln -s /dev/null /etc/systemd/network/99-default.link diff --git a/builder/files/etc/rc.local b/builder/files/etc/rc.local deleted file mode 100755 index 65634df..0000000 --- a/builder/files/etc/rc.local +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -e -# -# rc.local -# -# This script is executed at the end of each multiuser runlevel. -# Make sure that the script will "exit 0" on success or any other -# value on error. -# -# In order to enable or disable this script just change the execution -# bits. -# -# By default this script does nothing. - -exit 0 diff --git a/builder/files/etc/rpicam_config.txt b/builder/files/etc/rpicam_config.txt deleted file mode 100644 index 325c3f4..0000000 --- a/builder/files/etc/rpicam_config.txt +++ /dev/null @@ -1,8 +0,0 @@ -rpicamdir="cam" -webserver="" -webport="80" -user="" -webpasswd="" -autostart="yes" -jpglink="no" -phpversion="7"