-
-
Notifications
You must be signed in to change notification settings - Fork 255
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding a webserver to show installation log #372
Conversation
adds a lightweight webserver to shows the first-boot.log in users browser Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
+ adding no cache options to the html page + some code formatting fixes Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
GitHub Desktop code preview seems to shows things different than the website Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
Hey! Using the python webserver was also my first idea. A problem I'm seeing is that it first needs to be installed... which is kinda contradictory to our goal: showing the progress and potential errors of the installation. I was hoping to use an application preinstalled or to ship a portable binary. Did you see: https://github.com/benrady/shinatra/blob/master/shinatra.sh |
I am amazed 😄 #!/usr/bin/env bash
CONTENT="$(cat /boot/first-boot.log)"
RESPONSE="HTTP/1.1 200 OK\r\nConnection: keep-alive\r\n\r\n${2:-"$CONTENT"}\r\n"
while { echo -en "$RESPONSE"; } | nc -l "${1:-8888}"; do : ; done |
well python is shipped with raspbian, so no need to install something first |
Also on Raspbian Lite? Has been a long time since I last checked. By all means, if this is the case, let's use python. |
@@ -69,6 +69,7 @@ cp $sourcefolder/first-boot.sh $buildfolder/boot/first-boot.sh | |||
touch $buildfolder/boot/first-boot.log | |||
cp $sourcefolder/openhabian.raspbian.conf $buildfolder/boot/openhabian.conf | |||
unix2dos $buildfolder/boot/openhabian.conf | |||
cp $sourcefolder/webif.sh $buildfolder/boot/webif.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add to the pine script as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is there python also installed on pine?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will be taken care of in #358 will finish it up later this month.
build-rpi-raspbian/first-boot.sh
Outdated
@@ -5,6 +5,8 @@ exec &> >(tee -a "/boot/first-boot.log") | |||
|
|||
timestamp() { date +"%F_%T_%Z"; } | |||
|
|||
sh /boot/webif.sh start |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please move below function fail_inprogress
and add a comment or log line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i moved it below Storing configuration
, so we can get the hostname out of openhabian.conf
build-rpi-raspbian/first-boot.sh
Outdated
@@ -83,6 +85,7 @@ apt update &>/dev/null | |||
apt --yes upgrade &>/dev/null | |||
if [ $? -eq 0 ]; then echo "OK"; else echo "FAILED"; fail_inprogress; fi | |||
|
|||
sh /boot/webif.sh restart |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in case the python process gets killed by a python package upgrade
build-rpi-raspbian/webif.sh
Outdated
# cleanup: stops the webserver | ||
# removes all no longer needed files | ||
|
||
hostname=openhabianpi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
doesn't have to be true, please take from openhabian.conf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
build-rpi-raspbian/webif.sh
Outdated
# removes all no longer needed files | ||
|
||
hostname=openhabianpi | ||
port=8888 # Port the webserver is listing to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
how about 80?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changed to port 80
build-rpi-raspbian/webif.sh
Outdated
port=8888 # Port the webserver is listing to | ||
|
||
if [ $1 = "start" ]; then | ||
mkdir /tmp/webif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please reindent the whole script
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry i don't understand what you mean
build-rpi-raspbian/webif.sh
Outdated
if [ $1 = "start" ]; then | ||
mkdir /tmp/webif | ||
ln -s /boot/first-boot.log /tmp/webif/first-boot.txt | ||
cd /tmp/webif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can often become an issue of confusion. Please work with absolute paths and without cd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
now using absolute paths
build-rpi-raspbian/webif.sh
Outdated
<meta http-equiv="Expires" content="0" /> | ||
</head>" > index.html | ||
echo "<body> | ||
<h1>OpenHabian Installation Status</h1> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
openHABian :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ups, corrected
build-rpi-raspbian/webif.sh
Outdated
cd /tmp/webif | ||
echo "<html> | ||
<head> | ||
<title>OpenHABian</title> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
openHABian please :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ups again, also corrected
build-rpi-raspbian/webif.sh
Outdated
echo "<body> | ||
<h1>OpenHabian Installation Status</h1> | ||
the log will be refreshed automatically every 10 seconds | ||
<iframe src="http://$hostname:$port/first-boot.txt" scrolling="yes" width="100%" height="90%"></iframe> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you still think this is needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
needed for what?
Left a few comments. Mostly about personal preferences. In general I'd say this looks like a huge improvement for our users ;) |
changed port to 80 corrected typos Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
so we can get hostname from openhabian.conf Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
the "requested" changes are done, but 2 things were unclear to me, please see the my reply to the comments |
Regarding intention: Some lines are indented with 8 spaces, others with a single tab. The project style is two spaces. Regarding iframe: Never mind. I guess it makes sense. Great work! Regarding pine: I don't know. @EliasGabrielsson any idea? |
build-rpi-raspbian/webif.sh
Outdated
<title>openHABian</title> | ||
</head>" > index.html | ||
echo "<body> | ||
<h1>OpenHabian Installation Status</h1> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missed one... :)
build-rpi-raspbian/webif.sh
Outdated
if [ -z $webifrunning ]; then | ||
python3 -m http.server $port > /dev/null 2>&1 & | ||
fi | ||
fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's named "restart" but that's not actually what it does.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
renamed to stillrunning
build-rpi-raspbian/webif.sh
Outdated
</head>" > /tmp/webif/index.html | ||
echo "<body> | ||
<h1>openHABian Installation Status</h1> | ||
the log will be refreshed automatically every 10 seconds |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
5 seconds?
+ fixed a typo Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
@ThomDietrich changed the code formatting, to match the project style better, also renamed the 'function' Also sorry for the delay, had two really busy weeks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, no worries. We are all doing this stuff in our spare time ;) I left another set of comments. Let me know if anything is unclear. Thanks !
fi | ||
|
||
if [ $1 = "cleanup" ]; then | ||
kill $(ps -ef | pgrep python3) > /dev/null && rm -R /tmp/webif > /dev/null |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could this query be too aggressive?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think so
while the installation is running, there are no other python3 activity
also the web server is not writing anything to files, so the kill will not cause any trouble
build-rpi-raspbian/webif.sh
Outdated
</head>" > index.html | ||
echo "<body> | ||
<h1>openHABian Installation Status</h1> | ||
installation is done, you can now access the your openHAB Installation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Installation successful. You can now access the openHAB dashboard using this link.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sounds better indeed
</head>" > /tmp/webif/index.html | ||
echo "<body> | ||
<h1>openHABian Installation Status</h1> | ||
the log will be refreshed automatically every 10 seconds |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My question regarding 10 seconds was aimed at http-equiv="refresh" content="5"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a leftover from my tests, this line will be removed in the next commit
build-rpi-raspbian/first-boot.sh
Outdated
sleep 10 | ||
sh /boot/webif.sh inst_done | ||
sleep 10 | ||
sh /boot/webif.sh cleanup |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the idea here. Won't the user be confused if the page is suddenly gone?
Is there any good reason to not just show the whole log until the user decides to eventually restart the system for the first time? The only thing i can think of would be the subsequent installation of a webserver which wants to use the port 80.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the web server will be gone, that is correct, but the page is still shown in the open browser, since the refresh from iframe isn't there anymore at this stage.
the sleeps are there to make sure that the open browser will fetch the site updates, i will increase the sleep to 12 seconds, to give the browser a little more time to do so
my thought behind this, was simply to not have running any services that are not needed anymore.
but yes, in case the user is trying to access after the installation is already done he will get an 404.
Not sure if we should keep the web server running for this case, i make it your decision :)
build-rpi-raspbian/webif.sh
Outdated
python3 -m http.server $port > /dev/null 2>&1 & | ||
fi | ||
|
||
if [ $1 = "stillrunning" ]; then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about reinsure_running
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure :)
build-rpi-raspbian/first-boot.sh
Outdated
@@ -23,6 +23,10 @@ sed -i 's/\r$//' /etc/openhabian.conf | |||
source /etc/openhabian.conf | |||
echo "OK" | |||
|
|||
echo -n "$(timestamp) [openHABian] Starting webserver... " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about a little bit more information... "Starting webserver with installation log... "
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sounds good
build-rpi-raspbian/webif.sh
Outdated
<iframe src="http://$hostname:$port/first-boot.txt" scrolling="yes" width="100%" height="90%"></iframe> | ||
</body> | ||
</html>" >> /tmp/webif/index.html | ||
python3 -m http.server $port > /dev/null 2>&1 & |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd actually suggest to remove 2>&1
as it's stderr output could certainly be useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also the command as it is will not show your content. I'd suggest:
(cd /tmp/webif; python3 -m http.server $port > /dev/null)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes it removes the stderr ourput, but also the normal output, otherwise we will see the http-request messages every 10 seconds and i found this really annoying
thank you for the command part, i will do this in the next commit
build-rpi-raspbian/first-boot.sh
Outdated
@@ -23,6 +23,10 @@ sed -i 's/\r$//' /etc/openhabian.conf | |||
source /etc/openhabian.conf | |||
echo "OK" | |||
|
|||
echo -n "$(timestamp) [openHABian] Starting webserver... " | |||
sh /boot/webif.sh start | |||
echo "OK" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not necessarily...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added a check if the web server is running with according output to the log
- renamed 'function' stillrunning -> reinsure_running - improved installation improved msg Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
... and added according output to the log - renamed the 'function' stillrunning -> reinsure_running - increased time before running inst_done and cleanup Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
Sorry for the long delay. Are we ready to merge? One last thing I need to ask from you: Could you please open a new PR addressing the new feature in documentation: https://github.com/openhab/openhabian/blob/master/docs/openhabian.md#did-my-installation-succeed-what-to-do-in-case-of-a-problem |
fd0e6d0
to
47771f8
Compare
@ThomDietrich yes we are almost ready to merge, still not sure about the pine -> #372 (review) the PR for the documentation is on it's way |
Ah, #372 (review) yes... @EliasGabrielsson would you be able to comment on this? |
I've created a new issue for the last remaining question. |
@mues-lee thanks again for this great contribution! |
* adding a webserver adds a lightweight webserver to shows the first-boot.log in users browser Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * modifications for webserver addition Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * adding webif file to image Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * moving webif.sh to correct folder + adding no cache options to the html page + some code formatting fixes Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * code formatting GitHub Desktop code preview seems to shows things different than the website Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * getting hostname from openhabian.conf changed port to 80 corrected typos Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * changed start time of webserver so we can get hostname from openhabian.conf Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * 'function' renamed, code formatting improved + fixed a typo Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * 'function' renamed Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * fixed bug, that prevent starting the webserver - renamed 'function' stillrunning -> reinsure_running - improved installation improved msg Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Added check if web server is started ... ... and added according output to the log - renamed the 'function' stillrunning -> reinsure_running - increased time before running inst_done and cleanup Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) Signed-off-by: Marcus Krüger [email protected] (github: mues-lee)
* fix changing smbpasswd Signed-off-by: Markus Storm <[email protected]> * Download and install Zulu Embedded from .tar We need to change the installation method of Zulu Java as Azul systems does not maintain Java repos any more. * Download and install Zulu Embedded from .tar * Create azul_zulu_license.md * move setting Java options to openhab2_setup() * don't download to /tmp due to tmpfs potentially exceeded * latest zulu is 8u192 * java install into /opt/jdk and use local variables * java link correction * java link corrected * changes as requested by @ThomDietrich * reformat, add source link * rearranged java installation to catch errors untested for now * fix: create TEMPROOT * Update java-jre.sh Signed-off-by: Thomas Dietrich <[email protected]> * license -> docs * Create azul_zulu_license.md * Delete azul_zulu_license.md * license moved from docs to includes * Add newline before new entries in dashboard.cfg Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Add homegear repositories for supported systems (#297) * Fix #286 This adds support for all OSes supported by Homegear at the moment Signed-off-by: Lars Francke <[email protected]> (github: lfrancke) * Overwrite list file instead of appending to it Signed-off-by: Lars Francke <[email protected]> (github: lfrancke) * Add short option to all lsb_release calls Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Fix Frontail setup function and service config #304 Signed-off-by: Markus Haack <[email protected]> (github: mhaack) * Add source front matter to USAGE file Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Add arping as basic package (#311) Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Changed Nginx script to explicit use external DNS Fixes #324 Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Minor amanda README fix (#314) * Start findserver after mosquitto (#328) Signed-off-by: Markus Storm [email protected] Github: mstormi * Add PINE64 support for system binding and gpio, close #310 (#322) * Added PINE64 support for system binding and gpio closes #310 Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Added newline to PINE64 gpio script Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Change "Manual/Fresh Setup" menu to checklist (#331) Fixes #250 Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Improve password change function and cleanup #326 (#332) * Nginx password change function and cleanup #326 * Added support to change the password for nginx access user #326 * Rewrite password menu to enable a dynamic view, eg. not all password are installed on all systems. * Updated documentaion to reflect reality concerning password handling. Signed-off-by: Elias Gabrielsson [email protected] (github: EliasGabrielsson) * InfluxDB/Grafana password change function #334 * Added support to change the password for Grafana and InfluxDB admin account #334 * Added password length check on 10 character to comply with Grafana Signed-off-by: Elias Gabrielsson [email protected] (github: EliasGabrielsson) * Add openhab user to bluetooth group (required for Bluetooth binding) (#338) Signed-off-by: Kai Kreuzer <[email protected]> * Mount vfat storage stick as user backup in example (#340) Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Fix function call typo (#344) Fixes #341 Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Update README.md * Remove commandline openhab-generator, closes #329 (#335) * Removed commandline openhab-generator closes: #329 Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Updated README to refer to Home Builder Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Update openhabian.md * Restore ability to choose new conffile or not Signed-off-by: Ben Clark <[email protected]> * Fix unstable function call naming Signed-off-by: Ben Clark <[email protected]> * Improve fstab pattern-based share delete, fix #349 Fixes #349 Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Fix failing Amanada tape symlink creation (#354) * fixing failing drive0 and drive1 symlink creation target folder for ln -s ${storage}/slots ${storage}/slots/drive0;ln -s ${storage}/slots ${storage}/slots/drive1 doesn't exist, to avoid the creation fail the need folder is created in before * adding the correct ownership to slots folder as suggested by @mstormi in #354 Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * adding the correct ownership to slots folder as suggested by @mstormi in #354 Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Remove deletion of rpi-update (#359) * Re-add rpi-update to basic packages Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Update system.sh Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Execute apt update after upgrade (#360) * get latest repository data before git install Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Replicate change for pinea64 Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Add console width check, close #345 (#361) Signed-off-by: Elias Gabrielsson [email protected] (github: EliasGabrielsson) * Decrease width of warning, fix typos (#363) Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Fix typo in samba password change function Signed-off-by: Ben Clark <[email protected]> * updating grafana repository to use stretch builds (#365) * updating grafana repository to use stretch builds Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * grafana/InfluxDB source-list based on current OS closes #367 also added source-list based on os for InfluxDB Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * grafana: restoring Ubuntu xenial compatibility Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Add is_pithreeplus helper function, closes #374 (#376) * is_pithreeplus( ) added Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * is_pithreeplus( ) added Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * is_pithreeplus( ) added Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Update wifi function for stretch, resolves #374 Resolves #374 Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Update Node.JS installer to use v8 (from v7) (#383) * Update installer to use Node.js 8 (from v7) Installation of fronttail was failing on Ubuntu distributions newer than Zesty because they were not supported by Node v7. This patch changes the installed version of Node to 8 in the openhabian-setup.sh installer. Signed-off-by: Brian Warner <[email protected]> * Update nodejs-apps.sh Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Update Node.JS installer to use Carbon for ARMv6l This patch updates the installed version of Node.JS from Boron to Carbon. This is an LTS release supported through December 2019. Signed-off-by: Brian Warner <[email protected]> * Enables wifi by removing soft block (#380) The latest version of openhabian on the rpi soft locks the wifi and prevents enabling of wifi. This removes the soft block and enables wifi. Signed-off-by: Jeremy Scott [email protected] (github: jscottnz) * Removes wpa_supplicant.conf on failed start so the user has a chance to correct it (#386) Also-by: Thomas Dietrich [email protected] (github: ThomDietrich) Signed-off-by: Jeremy Scott [email protected] (github: jscottnz) * Corrected misspelling (#394) Reference: openhab/openhab-docs#676 Signed-off-by: Jerome Luckenbach <[email protected]> * Add amanda settings backup, improve docs (#371) * amanda create config+index backup * amanda cron entry corrected * Corrected cron entry for amanda * Fixed Amanda backup tar destination dir, backup group * Amanda docs improvement on partition restoration * Amanda docs improvement on partition restoration * Amanda emergency recovery howto * fix Amanda config+index backup cronjob * Amanda docs typos * Update openhabian-amanda.md Signed-By: Markus Storm <[email protected]> (github: mstormi) * Set Amanda SD card default size, increase net bandwidth (#370) * amanda.conf SD card default size, net bandwidth increased * Amanda docs typos * Update openhabian-amanda.md Signed-off-by: Markus Storm [email protected] (github: mstormi) * Retrieve gpg key unconditionally in openHAB setup Resolves #393 Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Fixed syntax error in backup.sh (#397) Added missing " * Add travis.yml Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Update documentation links Signed-off-by: Wouter Born <[email protected]> * Install distro specific versions of certbot (#403) * Install distro specific versions of certbot Signed-off-by: Ben Clark <[email protected]> * Fix package to install being null for Ubuntu Signed-off-by: Ben Clark <[email protected]> * Reinstate and rerun upgrade during first-boot (#405) If updating repositories and upgrading installed packages fails, give it another chance with reinstating dpkg. Signed-off-by: Alari Truuts <[email protected]> (github: Alluuu) * Generalise stable version in menu (#409) * Generalise stable version in menu Signed-off-by: Ben Clark <[email protected] * Remove use of ".X" Signed-off-by: Ben Clark <[email protected]> * Add a webserver to show log during RPi first-boot (#372) * adding a webserver adds a lightweight webserver to shows the first-boot.log in users browser Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * modifications for webserver addition Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * adding webif file to image Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * moving webif.sh to correct folder + adding no cache options to the html page + some code formatting fixes Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * code formatting GitHub Desktop code preview seems to shows things different than the website Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * getting hostname from openhabian.conf changed port to 80 corrected typos Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * changed start time of webserver so we can get hostname from openhabian.conf Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * 'function' renamed, code formatting improved + fixed a typo Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * 'function' renamed Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * fixed bug, that prevent starting the webserver - renamed 'function' stillrunning -> reinsure_running - improved installation improved msg Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Added check if web server is started ... ... and added according output to the log - renamed the 'function' stillrunning -> reinsure_running - increased time before running inst_done and cleanup Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) Signed-off-by: Marcus Krüger [email protected] (github: mues-lee) * Provide generic hostname in custom dashboard tiles. Closes #287, Fixes #389 Signed-off-by: Kuba Wolanin <[email protected]> * Fixed broken Anchor (#417) Seems the corresponding headline was renamed. Signed-off-by: Jerome Luckenbach <[email protected]> * add optional component "Tellstick core service" (#390) This patch add a install script for usb based Tellstick devices. It consist of three parts: 1) The tool, driver and service itself. 2) A custom systemd service for autostart. 3) Installation of an improved administration tool for device detection. Signed-off-by: Elias Gabrielsson [email protected] (github: EliasGabrielsson) * merge buildchain and add custom repositories (#358) This patch: * merge `first-boot.sh` files to a common one for all platforms with conditional actions * merged build script to a common one, `build.sh` * adds to build options for custom repositories, `dev-git` and `dev-url` * adds `test build` watermark to builds created with `dev-git` and `dev-url` * enables web gui for pine64 board Things to note: * Adds dependency to `functions/helpers.sh` Closes issue #269 Signed-off-by: Elias Gabrielsson [email protected] (github: EliasGabrielsson) * Set wifi country for wireless regulatory domain (#384) * Fixes wifi country for wireless regulatory domain - adds `wifi_country` to config with comment. Defaults to US - uses `wifi_country` to configure wifi correctly - updates `functions/wifi.sh` to collect and configure `wifi_country` Closes issue #382 Signed-off-by: Jeremy Scott [email protected] (github: jscottnz) * Update first-boot.sh * Update openhabian.pi-raspbian.conf * Update openhabian.pine64-xenial.conf * Update openhabian.pine64-xenial.conf * Add Speedtest-cli as optional component (#421) * Add Speedtest-cli optional component Signed-off-by: Kuba Wolanin <[email protected]> * Update menu.sh Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Update packages.sh Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Update packages.sh Signed-off-by: Thomas Dietrich <[email protected]> (github: ThomDietrich) * Support IPv4 link-local routes (169.254.x.x) (#434) Signed-off-by: Elias Gabrielsson <[email protected]> (github: EliasGabrielsson) * Added option to install openHAB milestone builds (#436) * Added option to install openHAB milestone builds Now that there's 'milestone' builds made available in the openHAB testing repository, we should offer openHABian users to use these. Signed-off-by: Markus Storm [email protected] (github: mstormi) * Added option to install openHAB milestone builds Added option to install openHAB milestone builds Signed-off-by: Markus Storm [email protected] (github: mstormi) * testing artefact removed * changed testing repo, modified wording according to bclark09's comments * wording of OH releases: milestone -> testing * added testing buills under option 64 * minor wording changes and typos (#440) * optimize Java memory allocation for low-mem SBCs (#443) See issue #442 Signed-off-by: Markus Storm [email protected] (github: mstormi) * refactored Amanda AWS backup option (#449) refactored all of Amanda install routine setting up AWS S3 backup didn't work at all, now it does (hopefully) Signed-off-by: Markus Storm [email protected] (github: mstormi)) * Download and install Zulu Embedded from .tar We need to change the installation method of Zulu Java as Azul systems does not maintain Java repos any more. * Download and install Zulu Embedded from .tar * Create azul_zulu_license.md * move setting Java options to openhab2_setup() * Set Java memory opts (moved from java-jre.sh) (#460) * Set Java memory opts (moved from java-jre.sh) * move setting Java memory options to openhab2_setup() fix #454 * don't download to /tmp due to tmpfs potentially exceeded * latest zulu is 8u192 * java install into /opt/jdk and use local variables * java link correction * java link corrected * maybe a bit too many warnings (#464) Got feedback that's "intimidating" to Linux newbies and made them stay away from using it. * Updated list of optional openHABian components (#466) * Updated list of optional components * Update openhabian.md * Node-RED Install (#420) * Changes so that Node-RED installs and runs as the openhabian user rather than root * Updated to use $username variable rather than explicit username * Fix sed expression to remove blank lines from /etc/fstab (#455) * Change from apt to apt-get in build (#472) Signed-off-by: Elias Gabrielsson <[email protected]> * removed changerfile from amanda.conf (#474) deprecated in Amanda 3.4+ * Multitail update (#481) * Add own multitail configuration Signed-off-by: Thomas Dietrich <[email protected]> * Add multitail config to manual setup Signed-off-by: Thomas Dietrich <[email protected]> * Add fully scripted influxdb + grafana installation (#465) Closes #366 Partly-resolves #437 This patch aims to script the installation instructions found: https://community.openhab.org/t/influxdb-grafana-persistence-and-graphing/13761 Signed-off-by: Elias Gabrielsson <[email protected]> * Fixed syntax error InfluxDB+Grafana installation (#486) Resolves #484 Signed-off-by: Elias Gabrielsson <[email protected]> * Fixes bug in openhabian-config help menu (#438) (#483) Fixes #438 Closes #438 This simple patch fixes a minor issue when pressing Esc on the Help menu of openhabian-config. signed-off-by: Tyler Walker <[email protected]> (github: Tylerbinski) * specify openhab2 package version (#476) * specify openhab2 package version required if moving from snapshot to milestone else won't obtain that * typo in package name corrected * Remove unused Java installation code (#490) Signed-off-by: Elias Gabrielsson <[email protected]> * Zulu repo (#491) * Remove unused Java installation code Signed-off-by: Elias Gabrielsson <[email protected]> * Base Zulu Java installation on distrubition Resolves #368 Signed-off-by: Elias Gabrielsson <[email protected]> * changes as requested by @ThomDietrich * reformat, add source link * rearranged java installation to catch errors untested for now * fix: create TEMPROOT * Update java-jre.sh Signed-off-by: Thomas Dietrich <[email protected]> * license -> docs * Create azul_zulu_license.md * Delete azul_zulu_license.md * license moved from docs to includes * remove Oracle java from options
using python3 to create a lightweight webserver to show the first-boot.log in the browser
what is it doing?
after apt-update & upgrade
as mentioned in #357