Docker für Wireguard Gateway vorher/nachher?

Einrichtung der openHAB Umgebung und allgemeine Konfigurationsthemen.

Moderatoren: seppy, udo1toni

Antworten
Boris099
Beiträge: 383
Registriert: 19. Feb 2020 20:51
Answers: 3
Wohnort: Saarbrücken

Docker für Wireguard Gateway vorher/nachher?

Beitrag von Boris099 »

Pi4, Openhabian3.2, per LAN angeschlossen, fixe IP

Ich bin immer noch dabei Openhabian3.2 aufzusetzen, und nun stellt sich mir die Frage, ob ich denn evtl. auch Docker aufsetzen soll?
Nun habe ich das Netz mal etwas befragt und das bringt aber mir keine Erleuchtung :-), oder tue ich mir dann nur etwas ans Bein hängen,
was ich gar nicht brauche?
1. Muss ich Docker vorher oder nach OH3 installieren?
2. Bleibt der OH-Update Prozess in einem Container identisch?
3. Was schützt denn ein Container wirklich, bzw. was benutzen die Programme in den Container gemeinsam?

Nun zum eigentlichen Thema. Ich würde gerne ein Wireguard Gateway (bzw. Router) auf dem PI parallel laufen lassen.
Nur für ausgehende Verbindungen, also z.B. einen Firestick oder andere Geräte per Gateway auf den PI/Wireguard umlenken
und dessen Traffic dann über dieses VPN laufen lassen. Verwende ich hier sinnvoll Docker oder brauch ich das gar nicht?

Ich hatte mal unter OH2.5 RaspAP installiert, das spannt ein WLAN AccessPoint auf, eigentlich eine nette Idee aber das hat sich
mit OH nicht wirklich vertragen, da kamen schon bei der Installation "unschöne" Meldungen hoch, ich weiß heute nicht mehr genau
was das war, aber danach liefen entweder OH oder RaspAP nicht mehr stabil. Somit drängt sich mir Docker auf und was schützt
denn ein Container?

Nicht dass ich RaspAP nochmal installieren möchte, aber ich weiß nicht wirklich, wie ich denn das Wireguard Gateway aufbauen soll.
geht das evtl. mit PiHole, oder PiVPN, oder einfach mit openhabian-config Bordmitteln?

Ich verwende Cyberghost und sehe dass die eine Linux App für Debian basierte Distros anbieten, das möchte ich mal auf meinem
momentanen Testsystem installieren, ob das überhaupt auf dem OH3.2 läuft.
Raspberry 4, Rev.1.2b, 4GB, Openhab 2.5.12 (OH3 kommt im Winter dran:-))

Boris099
Beiträge: 383
Registriert: 19. Feb 2020 20:51
Answers: 3
Wohnort: Saarbrücken

Re: Docker für Wireguard Gateway vorher/nachher?

Beitrag von Boris099 »

Also kurzes Update für dieses Cyberghost package - es läuft nicht unter dem Pi OS.
Ich habe die Version für Ubuntu 20.04 genommen da dies auf Bullseye basiert, wie das Openhabian 3.2 auch.

Das bekam ich als log

Code: Alles auswählen

openhabian@openhabian:/home/Cyberghost $ sudo bash install.sh

CyberGhost Installer ...

No LSB modules are available.
No LSB modules are available.
Checking if glibc version is compatible
Couldn't detect a valid version of your distribution.
Make sure you have downloaded the correct install package for your distribution
Note: We support only the following distributions for Debian based OS:

-Ubuntu 16.04
-Ubuntu 18.04
-Ubuntu 19.04
-Ubuntu 19.10
-Ubuntu 20.04
-Linux Mint 19.2
-Linux Mint 20
-PopOS 19.10
-Kali 2019/2020 (glibc version should be 2.29/2.30/2.31 in order to work)
Raspberry 4, Rev.1.2b, 4GB, Openhab 2.5.12 (OH3 kommt im Winter dran:-))

Benutzeravatar
udo1toni
Beiträge: 15265
Registriert: 11. Apr 2018 18:05
Answers: 245
Wohnort: Darmstadt

Re: Docker für Wireguard Gateway vorher/nachher?

Beitrag von udo1toni »

Es reicht nicht, wenn bullseye drauf steht, es muss auch arm drin sein :)

Das gilt im Übrigen auch, wenn Du Docker nutzt.

Docker dient vor allem dem separieren von Prozessen. Gemeinsam genutzt wird der gesamte Unterbau, wobei jedes Programm, was in einem Docker Container läuft, das System so sieht, als sei es allein auf weiter Flur. Damit kann man vor allem Probleme bei überlappenden Ressourcen in den Griff bekommen, z.B. zwei Programme, die beide Port 8080 verwenden. entweder, man bridged das Netz und die Container haben anschließend unterschiedliche IP-Adressen, oder man verschiebt dern Portbereich des einen Containers in einen ungenutzten Bereich.

Es gibt extra vorbereitete Docker Container von openHAB, und zwar für praktisch alle Versionen, wobei vermutlich nicht jeder der Versionen sauber laufen wird, aber alles nach 3.0 sollte eigentlich funktionieren.
Der große Vorteil von Docker (in Bezug auf openHAB) ist, dass Du den Container einfach weg schmeißt und einen neuen erzeugst, wenn Du z.B. ein Update haben willst. Dabei dauert derPull des Containers allgemein nicht länger als der Download der zip-Datei. Mit Portainer gibt es auch ein Webfrontend, welches selbst als Container läuft. Portainer ist dann auch der einzige container, den du über die Konsole upgraden musst...
openHAB4.3.5 stable in einem Debian-Container (bookworm) (Proxmox 8.4.1, LXC), mit openHABian eingerichtet

Boris099
Beiträge: 383
Registriert: 19. Feb 2020 20:51
Answers: 3
Wohnort: Saarbrücken

Re: Docker für Wireguard Gateway vorher/nachher?

Beitrag von Boris099 »

Nach Recherche im Netz (das warst glaube ich auch Du) wird erst PiOS light, dann Docker und dann ein Container mit Portainer installiert.
Aber da muß man bei Openhab ganz schön schrauben, bis es wir OpenHabian steht, korrekt?
Geht denn alternativ auch Openhabian als Basis und dann Docker, um z.B. lediglich RaspAP separat in einem Container laufen zu lassen?

Dieses RaspAP bietet nun neben dem AP auch die Möglichkeit gleich noch ein VPN Gateway einzubinden.
Das RaspAP hatte ich damals unter Openhabian (glaube noch 1.6 oder 2.1) schon mal installiert und das lief nicht stabil, weiß nicht mehr warum...
Allerdings konnte man damals noch kein VPN einbinden, also in der Applikation sozusagen für Dummys:-)
Also klingt mir dieses Tool nun noch verlockender, ich habe noch meine OH3.2 Testinstallation auf meinem alten Pi3b da hau ich das RaspAP
mal drauf und schau mal, was das ohne Docker, direkt in Openhabian, so treibt.

Auf der RaspAP Seite gibt es auch einen Link für eine manuelle Installation, vielleicht sagt dir das was da so passiert, und ob das riskant ist,
das direkt in Openhabian zu installieren?
https://docs.raspap.com/manual/
Raspberry 4, Rev.1.2b, 4GB, Openhab 2.5.12 (OH3 kommt im Winter dran:-))

Boris099
Beiträge: 383
Registriert: 19. Feb 2020 20:51
Answers: 3
Wohnort: Saarbrücken

Re: Docker für Wireguard Gateway vorher/nachher?

Beitrag von Boris099 »

Das ist das Installation Log von RaspAP (ganz schön viel :-))
Ich mache jetzt mal einen Restart...

Update: Im Augenblick läuft beides, ich lass das jetzt mal in Ruhe und schaue nachher nochmal.
DSL Speedtest - bei meiner 100Mbps Leitung schafft der AP vom Pi3b auf dem Handy Down 28,97 Mbps, Up 31,29 Mbps, gar nicht schlecht
aber der Ping ist grottige 119 ms.

Ich kann mich erinnern, dass damals häufig der AP einfach weg war, schau mer mal

Code: Alles auswählen

openhabian@openhabian:~ $ curl -sL https://install.raspap.com | bash


 888888ba                              .d888888   888888ba
 88     8b                            d8     88   88     8b
a88aaaa8P' .d8888b. .d8888b. 88d888b. 88aaaaa88a a88aaaa8P
 88    8b. 88    88 Y8ooooo. 88    88 88     88   88
 88     88 88.  .88       88 88.  .88 88     88   88
 dP     dP  88888P8  88888P  88Y888P  88     88   dP
                             88
                             dP      version 2.8.3

The Quick Installer will guide you through a few easy steps


RaspAP Install: Configure installation
Detected OS: Raspbian GNU/Linux 11 (bullseye)
Using GitHub repository: RaspAP/raspap-webgui 2.8.3 branch
Configuration directory: /etc/raspap
lighttpd root: /var/www/html? [Y/n]: Y
Installing lighttpd directory: /var/www/html
Complete installation with these values? [Y/n]: Y
RaspAP Install: Updating sources
[sudo] password for openhabian:
Get:1 http://davesteele.github.io/comitup/repo comitup InRelease [3,936 B]
Hit:2 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
Hit:3 http://archive.raspberrypi.org/debian bullseye InRelease
Hit:4 https://deb.nodesource.com/node_14.x bullseye InRelease
Hit:5 https://openhab.jfrog.io/artifactory/openhab-linuxpkg stable InRelease
Fetched 3,936 B in 2s (1,866 B/s)
Reading package lists...
RaspAP Install: Installing required packages
Reading package lists...
Building dependency tree...
Reading state information...
git is already the newest version (1:2.30.2-1).
The following additional packages will be installed:
  dns-root-data dnsmasq-base iptables libip6tc2 libnetfilter-conntrack3
  libnfnetlink0 libqrencode4 libsodium23 lighttpd-mod-deflate
  lighttpd-mod-openssl netfilter-persistent php-common php7.4-cli
  php7.4-common php7.4-json php7.4-opcache php7.4-readline spawn-fcgi
Suggested packages:
  firewalld rrdtool php-fpm apache2-utils lighttpd-doc
  lighttpd-mod-authn-gssapi lighttpd-mod-authn-pam lighttpd-mod-authn-sasl
  lighttpd-mod-geoip lighttpd-mod-maxminddb lighttpd-mod-trigger-b4-dl
  lighttpd-mod-vhostdb-pgsql lighttpd-mod-webdav lighttpd-modules-dbi
  lighttpd-modules-ldap lighttpd-modules-lua lighttpd-modules-mysql php-pear
  vnstati
The following NEW packages will be installed:
  dns-root-data dnsmasq dnsmasq-base hostapd iptables iptables-persistent
  libip6tc2 libnetfilter-conntrack3 libnfnetlink0 libqrencode4 libsodium23
  lighttpd lighttpd-mod-deflate lighttpd-mod-openssl netfilter-persistent
  php-common php7.4-cgi php7.4-cli php7.4-common php7.4-json php7.4-opcache
  php7.4-readline qrencode spawn-fcgi vnstat
0 upgraded, 25 newly installed, 0 to remove and 0 not upgraded.
Need to get 5,264 kB of archives.
After this operation, 24.3 MB of additional disk space will be used.
Do you want to continue? [Y/n] Get:1 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf hostapd armhf 2:2.9.0-21 [665 kB]
Get:2 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf libip6tc2 armhf 1.8.7-1 [33.0 kB]
Get:3 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf libnfnetlink0 armhf 1.0.1-3+b1 [12.4 kB]
Get:4 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf libnetfilter-conntrack3 armhf 1.0.8-3 [32.5 kB]
Get:5 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf iptables armhf 1.8.7-1 [328 kB]
Get:6 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf netfilter-persistent all 1.0.15 [11.0 kB]
Get:7 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf iptables-persistent all 1.0.15 [12.4 kB]
Get:8 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf lighttpd armhf 1.4.59-1 [313 kB]
Get:9 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf vnstat armhf 2.6-3 [88.2 kB]
Get:10 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf dns-root-data all 2021011101 [5,524 B]
Get:11 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf dnsmasq-base armhf 2.85-1 [416 kB]
Get:12 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf dnsmasq all 2.85-1 [32.0 kB]
Get:13 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf libqrencode4 armhf 4.1.1-1 [36.2 kB]
Get:14 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf libsodium23 armhf 1.0.18-1 [143 kB]
Get:15 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf lighttpd-mod-deflate armhf 1.4.59-1 [8,908 B]
Get:16 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf lighttpd-mod-openssl armhf 1.4.59-1 [16.5 kB]
Get:17 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf php-common all 2:76 [15.6 kB]
Get:18 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf php7.4-common armhf 7.4.25-1+deb11u1 [589 kB]
Get:19 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf php7.4-json armhf 7.4.25-1+deb11u1 [16.8 kB]
Get:20 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf php7.4-opcache armhf 7.4.25-1+deb11u1 [168 kB]
Get:21 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf php7.4-readline armhf 7.4.25-1+deb11u1 [10.9 kB]
Get:22 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf php7.4-cli armhf 7.4.25-1+deb11u1 [1,145 kB]
Get:23 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf php7.4-cgi armhf 7.4.25-1+deb11u1 [1,110 kB]
Get:24 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf qrencode armhf 4.1.1-1 [41.0 kB]
Get:25 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf spawn-fcgi armhf 1.6.4-2 [13.9 kB]
Preconfiguring packages ...
Fetched 5,264 kB in 4s (1,215 kB/s)
Selecting previously unselected package hostapd.
(Reading database ... 54524 files and directories currently installed.)
Preparing to unpack .../0-hostapd_2%3a2.9.0-21_armhf.deb ...
Unpacking hostapd (2:2.9.0-21) ...
Selecting previously unselected package libip6tc2:armhf.
Preparing to unpack .../1-libip6tc2_1.8.7-1_armhf.deb ...
Unpacking libip6tc2:armhf (1.8.7-1) ...
Selecting previously unselected package libnfnetlink0:armhf.
Preparing to unpack .../2-libnfnetlink0_1.0.1-3+b1_armhf.deb ...
Unpacking libnfnetlink0:armhf (1.0.1-3+b1) ...
Selecting previously unselected package libnetfilter-conntrack3:armhf.
Preparing to unpack .../3-libnetfilter-conntrack3_1.0.8-3_armhf.deb ...
Unpacking libnetfilter-conntrack3:armhf (1.0.8-3) ...
Selecting previously unselected package iptables.
Preparing to unpack .../4-iptables_1.8.7-1_armhf.deb ...
Unpacking iptables (1.8.7-1) ...
Selecting previously unselected package netfilter-persistent.
Preparing to unpack .../5-netfilter-persistent_1.0.15_all.deb ...
Unpacking netfilter-persistent (1.0.15) ...
Setting up libip6tc2:armhf (1.8.7-1) ...
Setting up libnfnetlink0:armhf (1.0.1-3+b1) ...
Setting up libnetfilter-conntrack3:armhf (1.0.8-3) ...
Setting up iptables (1.8.7-1) ...
update-alternatives: using /usr/sbin/iptables-legacy to provide /usr/sbin/iptables (iptables) in auto mode
update-alternatives: using /usr/sbin/ip6tables-legacy to provide /usr/sbin/ip6tables (ip6tables) in auto mode
update-alternatives: using /usr/sbin/iptables-nft to provide /usr/sbin/iptables (iptables) in auto mode
update-alternatives: using /usr/sbin/ip6tables-nft to provide /usr/sbin/ip6tables (ip6tables) in auto mode
update-alternatives: using /usr/sbin/arptables-nft to provide /usr/sbin/arptables (arptables) in auto mode
update-alternatives: using /usr/sbin/ebtables-nft to provide /usr/sbin/ebtables (ebtables) in auto mode
Selecting previously unselected package iptables-persistent.
(Reading database ... 54786 files and directories currently installed.)
Preparing to unpack .../00-iptables-persistent_1.0.15_all.deb ...
Unpacking iptables-persistent (1.0.15) ...
Selecting previously unselected package lighttpd.
Preparing to unpack .../01-lighttpd_1.4.59-1_armhf.deb ...
Unpacking lighttpd (1.4.59-1) ...
Selecting previously unselected package vnstat.
Preparing to unpack .../02-vnstat_2.6-3_armhf.deb ...
Unpacking vnstat (2.6-3) ...
Selecting previously unselected package dns-root-data.
Preparing to unpack .../03-dns-root-data_2021011101_all.deb ...
Unpacking dns-root-data (2021011101) ...
Selecting previously unselected package dnsmasq-base.
Preparing to unpack .../04-dnsmasq-base_2.85-1_armhf.deb ...
Unpacking dnsmasq-base (2.85-1) ...
Selecting previously unselected package dnsmasq.
Preparing to unpack .../05-dnsmasq_2.85-1_all.deb ...
Unpacking dnsmasq (2.85-1) ...
Selecting previously unselected package libqrencode4:armhf.
Preparing to unpack .../06-libqrencode4_4.1.1-1_armhf.deb ...
Unpacking libqrencode4:armhf (4.1.1-1) ...
Selecting previously unselected package libsodium23:armhf.
Preparing to unpack .../07-libsodium23_1.0.18-1_armhf.deb ...
Unpacking libsodium23:armhf (1.0.18-1) ...
Selecting previously unselected package lighttpd-mod-deflate.
Preparing to unpack .../08-lighttpd-mod-deflate_1.4.59-1_armhf.deb ...
Unpacking lighttpd-mod-deflate (1.4.59-1) ...
Selecting previously unselected package lighttpd-mod-openssl.
Preparing to unpack .../09-lighttpd-mod-openssl_1.4.59-1_armhf.deb ...
Unpacking lighttpd-mod-openssl (1.4.59-1) ...
Selecting previously unselected package php-common.
Preparing to unpack .../10-php-common_2%3a76_all.deb ...
Unpacking php-common (2:76) ...
Selecting previously unselected package php7.4-common.
Preparing to unpack .../11-php7.4-common_7.4.25-1+deb11u1_armhf.deb ...
Unpacking php7.4-common (7.4.25-1+deb11u1) ...
Selecting previously unselected package php7.4-json.
Preparing to unpack .../12-php7.4-json_7.4.25-1+deb11u1_armhf.deb ...
Unpacking php7.4-json (7.4.25-1+deb11u1) ...
Selecting previously unselected package php7.4-opcache.
Preparing to unpack .../13-php7.4-opcache_7.4.25-1+deb11u1_armhf.deb ...
Unpacking php7.4-opcache (7.4.25-1+deb11u1) ...
Selecting previously unselected package php7.4-readline.
Preparing to unpack .../14-php7.4-readline_7.4.25-1+deb11u1_armhf.deb ...
Unpacking php7.4-readline (7.4.25-1+deb11u1) ...
Selecting previously unselected package php7.4-cli.
Preparing to unpack .../15-php7.4-cli_7.4.25-1+deb11u1_armhf.deb ...
Unpacking php7.4-cli (7.4.25-1+deb11u1) ...
Selecting previously unselected package php7.4-cgi.
Preparing to unpack .../16-php7.4-cgi_7.4.25-1+deb11u1_armhf.deb ...
Unpacking php7.4-cgi (7.4.25-1+deb11u1) ...
Selecting previously unselected package qrencode.
Preparing to unpack .../17-qrencode_4.1.1-1_armhf.deb ...
Unpacking qrencode (4.1.1-1) ...
Selecting previously unselected package spawn-fcgi.
Preparing to unpack .../18-spawn-fcgi_1.6.4-2_armhf.deb ...
Unpacking spawn-fcgi (1.6.4-2) ...
Setting up lighttpd (1.4.59-1) ...
Created symlink /etc/systemd/system/multi-user.target.wants/lighttpd.service → /lib/systemd/system/lighttpd.service.
Setting up php-common (2:76) ...
Created symlink /etc/systemd/system/timers.target.wants/phpsessionclean.timer → /lib/systemd/system/phpsessionclean.timer.
Setting up lighttpd-mod-openssl (1.4.59-1) ...
Setting up libsodium23:armhf (1.0.18-1) ...
Setting up php7.4-common (7.4.25-1+deb11u1) ...

Creating config file /etc/php/7.4/mods-available/calendar.ini with new version

Creating config file /etc/php/7.4/mods-available/ctype.ini with new version

Creating config file /etc/php/7.4/mods-available/exif.ini with new version

Creating config file /etc/php/7.4/mods-available/fileinfo.ini with new version

Creating config file /etc/php/7.4/mods-available/ffi.ini with new version

Creating config file /etc/php/7.4/mods-available/ftp.ini with new version

Creating config file /etc/php/7.4/mods-available/gettext.ini with new version

Creating config file /etc/php/7.4/mods-available/iconv.ini with new version

Creating config file /etc/php/7.4/mods-available/pdo.ini with new version

Creating config file /etc/php/7.4/mods-available/phar.ini with new version

Creating config file /etc/php/7.4/mods-available/posix.ini with new version

Creating config file /etc/php/7.4/mods-available/shmop.ini with new version

Creating config file /etc/php/7.4/mods-available/sockets.ini with new version

Creating config file /etc/php/7.4/mods-available/sysvmsg.ini with new version

Creating config file /etc/php/7.4/mods-available/sysvsem.ini with new version

Creating config file /etc/php/7.4/mods-available/sysvshm.ini with new version

Creating config file /etc/php/7.4/mods-available/tokenizer.ini with new version
Setting up libqrencode4:armhf (4.1.1-1) ...
Setting up qrencode (4.1.1-1) ...
Setting up php7.4-readline (7.4.25-1+deb11u1) ...

Creating config file /etc/php/7.4/mods-available/readline.ini with new version
Setting up dnsmasq-base (2.85-1) ...
Setting up dns-root-data (2021011101) ...
Setting up dnsmasq (2.85-1) ...
Created symlink /etc/systemd/system/multi-user.target.wants/dnsmasq.service → /lib/systemd/system/dnsmasq.service.
Setting up hostapd (2:2.9.0-21) ...
Created symlink /etc/systemd/system/multi-user.target.wants/hostapd.service → /lib/systemd/system/hostapd.service.
Job for hostapd.service failed because the control process exited with error code.
See "systemctl status hostapd.service" and "journalctl -xe" for details.
Created symlink /etc/systemd/system/hostapd.service → /dev/null.
Setting up netfilter-persistent (1.0.15) ...
Created symlink /etc/systemd/system/multi-user.target.wants/netfilter-persistent.service → /lib/systemd/system/netfilter-persistent.service.
Setting up php7.4-opcache (7.4.25-1+deb11u1) ...

Creating config file /etc/php/7.4/mods-available/opcache.ini with new version
Setting up spawn-fcgi (1.6.4-2) ...
Setting up vnstat (2.6-3) ...
Created symlink /etc/systemd/system/multi-user.target.wants/vnstat.service → /lib/systemd/system/vnstat.service.
Setting up lighttpd-mod-deflate (1.4.59-1) ...
Setting up php7.4-json (7.4.25-1+deb11u1) ...

Creating config file /etc/php/7.4/mods-available/json.ini with new version
Setting up php7.4-cli (7.4.25-1+deb11u1) ...
update-alternatives: using /usr/bin/php7.4 to provide /usr/bin/php (php) in auto mode
update-alternatives: using /usr/bin/phar7.4 to provide /usr/bin/phar (phar) in auto mode
update-alternatives: using /usr/bin/phar.phar7.4 to provide /usr/bin/phar.phar (phar.phar) in auto mode

Creating config file /etc/php/7.4/cli/php.ini with new version
Setting up iptables-persistent (1.0.15) ...
update-alternatives: using /lib/systemd/system/netfilter-persistent.service to provide /lib/systemd/system/iptables.service (iptables.service) in auto mode
Setting up php7.4-cgi (7.4.25-1+deb11u1) ...
update-alternatives: using /usr/bin/php-cgi7.4 to provide /usr/bin/php-cgi (php-cgi) in auto mode
update-alternatives: using /usr/lib/cgi-bin/php7.4 to provide /usr/lib/cgi-bin/php (php-cgi-bin) in auto mode

Creating config file /etc/php/7.4/cgi/php.ini with new version
Processing triggers for man-db (2.9.4-2) ...
Processing triggers for dbus (1.12.20-2) ...
Processing triggers for libc-bin (2.31-13+rpt2+rpi1+deb11u2) ...
Processing triggers for php7.4-cli (7.4.25-1+deb11u1) ...
Processing triggers for php7.4-cgi (7.4.25-1+deb11u1) ...
Updating FireMotD available updates count ...
[ ✓ ok ]
RaspAP Install: Enabling PHP for lighttpd
Met dependency: fastcgi
Enabling fastcgi-php: ok
Enabling fastcgi: ok
Run "service lighttpd force-reload" to enable changes
RaspAP Install: Creating RaspAP directories
Creating /etc/raspap/networking
Adding /etc/dhcpcd.conf as base configuration
Changing file ownership of /etc/raspap
RaspAP Install: Optimize PHP configuration
Enable HttpOnly for session cookies (Recommended)? [Y/n]: Y
Php-cgi enabling session.cookie_httponly.
RaspAP Install: Backing up existing configs to /etc/raspap/backups
[ ✓ ok ]
RaspAP Install: Cloning latest files from github
Cloning into '/tmp/raspap-webgui'...
[ ✓ ok ]
RaspAP Install: Changing file ownership in web root directory
RaspAP Install: Creating hostapd logging & control scripts
[ ✓ ok ]
RaspAP Install: Creating lighttpd control scripts
Copying configport.sh to /etc/raspap/lighttpd
Changing file ownership
[ ✓ ok ]
RaspAP Install: Copying lighttpd extra config files
Copying 50-raspap-router.conf to /etc/lighttpd/conf-available
Creating link to /etc/lighttpd/conf-enabled
Existing 50-raspap-router.conf found. Unlinking.
unlink: cannot unlink '/etc/lighttpd/conf-enabled/50-raspap-router.conf': No such file or directory
Linking 50-raspap-router.conf to /etc/lighttpd/conf-enabled/
[ ✓ ok ]
RaspAP Install: Moving configuration file to /etc/raspap
changed ownership of '/etc/raspap/raspap.php' from root:root to www-data:www-data
RaspAP Install: Applying default configuration to installed services
Changing file ownership of /etc/raspap/networking//defaults.json
Checking for existence of /etc/dnsmasq.d
Copying bridged AP config to /etc/systemd/network
Copying primary RaspAP config to includes/config.php
[ ✓ ok ]
RaspAP Install: Configuring networking
Enabling IP forwarding
net.ipv4.ip_forward = 1
Restarting procps (via systemctl): procps.service.
Checking iptables rules
Adding rule: -t nat -A POSTROUTING -j MASQUERADE
Adding rule: -t nat -A POSTROUTING -s 192.168.50.0/24 ! -d 192.168.50.0/24 -j MASQUERADE
Persisting IP tables rules
Enable RaspAP control service (Recommended)? [Y/n]: Y
RaspAP Install: Enabling RaspAP daemon
Disable with: sudo systemctl disable raspapd.service
Created symlink /etc/systemd/system/multi-user.target.wants/raspapd.service → /lib/systemd/system/raspapd.service.
[ ✓ ok ]
RaspAP Install: Configure ad blocking (Beta)
Install ad blocking and enable list management? [Y/n]: Y
RaspAP Install: Creating ad blocking base configuration (Beta)
Creating /etc/raspap/adblock
Fetching latest hostnames list
/tmp/hostnames.txt  100%[===================>]   3.91M  9.53MB/s    in 0.4s
Fetching latest domains list
/tmp/domains.txt    100%[===================>]  11.55M  10.0MB/s    in 1.2s
Adding blocklists to /etc/raspap/adblock
Moving and setting permissions for blocklist update script
changed ownership of '/etc/raspap/adblock/domains.txt' from root:root to root:www-data
changed ownership of '/etc/raspap/adblock/hostnames.txt' from root:root to root:www-data
Adding 090_addblock.conf to /etc/dnsmasq.d
Enabling local DNS name resolution for DHCP clients
Enabling ad blocking management option
[ ✓ ok ]
RaspAP Install: Configure OpenVPN support
Install OpenVPN and enable client configuration? [Y/n]: Y
RaspAP Install: Installing OpenVPN and enabling client configuration
Adding packages via apt-get
Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  easy-rsa libccid liblzo2-2 libpkcs11-helper1 opensc opensc-pkcs11 pcscd
Suggested packages:
  pcmciautils openvpn-systemd-resolved
The following NEW packages will be installed:
  easy-rsa libccid liblzo2-2 libpkcs11-helper1 opensc opensc-pkcs11 openvpn
  pcscd
0 upgraded, 8 newly installed, 0 to remove and 0 not upgraded.
Need to get 2,183 kB of archives.
After this operation, 6,491 kB of additional disk space will be used.
Get:1 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf libccid armhf 1.4.34-1 [330 kB]
Get:2 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf pcscd armhf 1.9.1-1 [87.6 kB]
Get:3 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf easy-rsa all 3.0.8-1 [45.2 kB]
Get:4 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf liblzo2-2 armhf 2.10-2 [50.2 kB]
Get:5 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf libpkcs11-helper1 armhf 1.27-1 [42.8 kB]
Get:6 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf opensc-pkcs11 armhf 0.21.0-1 [772 kB]
Get:7 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf opensc armhf 0.21.0-1 [326 kB]
Get:8 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf openvpn armhf 2.5.1-3 [529 kB]
Preconfiguring packages ...
Fetched 2,183 kB in 2s (1,429 kB/s)
Selecting previously unselected package libccid.
(Reading database ... 55163 files and directories currently installed.)
Preparing to unpack .../0-libccid_1.4.34-1_armhf.deb ...
Unpacking libccid (1.4.34-1) ...
Selecting previously unselected package pcscd.
Preparing to unpack .../1-pcscd_1.9.1-1_armhf.deb ...
Unpacking pcscd (1.9.1-1) ...
Selecting previously unselected package easy-rsa.
Preparing to unpack .../2-easy-rsa_3.0.8-1_all.deb ...
Unpacking easy-rsa (3.0.8-1) ...
Selecting previously unselected package liblzo2-2:armhf.
Preparing to unpack .../3-liblzo2-2_2.10-2_armhf.deb ...
Unpacking liblzo2-2:armhf (2.10-2) ...
Selecting previously unselected package libpkcs11-helper1:armhf.
Preparing to unpack .../4-libpkcs11-helper1_1.27-1_armhf.deb ...
Unpacking libpkcs11-helper1:armhf (1.27-1) ...
Selecting previously unselected package opensc-pkcs11:armhf.
Preparing to unpack .../5-opensc-pkcs11_0.21.0-1_armhf.deb ...
Unpacking opensc-pkcs11:armhf (0.21.0-1) ...
Selecting previously unselected package opensc.
Preparing to unpack .../6-opensc_0.21.0-1_armhf.deb ...
Unpacking opensc (0.21.0-1) ...
Selecting previously unselected package openvpn.
Preparing to unpack .../7-openvpn_2.5.1-3_armhf.deb ...
Unpacking openvpn (2.5.1-3) ...
Setting up libccid (1.4.34-1) ...
Setting up pcscd (1.9.1-1) ...
Created symlink /etc/systemd/system/sockets.target.wants/pcscd.socket → /lib/systemd/system/pcscd.socket.
pcscd.service is a disabled or a static unit, not starting it.
Setting up liblzo2-2:armhf (2.10-2) ...
Setting up libpkcs11-helper1:armhf (1.27-1) ...
Setting up opensc-pkcs11:armhf (0.21.0-1) ...
Setting up easy-rsa (3.0.8-1) ...
Setting up openvpn (2.5.1-3) ...
Created symlink /etc/systemd/system/multi-user.target.wants/openvpn.service → /lib/systemd/system/openvpn.service.
Setting up opensc (0.21.0-1) ...
Processing triggers for man-db (2.9.4-2) ...
Processing triggers for mailcap (3.69) ...
Processing triggers for libc-bin (2.31-13+rpt2+rpi1+deb11u2) ...
Updating FireMotD available updates count ...
Enabling openvpn-client service on boot
Created symlink /etc/systemd/system/multi-user.target.wants/openvpn-client@client.service → /lib/systemd/system/openvpn-client@.service.
RaspAP Install: Creating OpenVPN control scripts
[ ✓ ok ]
RaspAP Install: Configure WireGuard support
Install WireGuard and enable VPN tunnel configuration? [Y/n]: Y
RaspAP Install: Configure WireGuard support
Installing wireguard from apt
Reading package lists...
Building dependency tree...
Reading state information...
The following additional packages will be installed:
  wireguard-tools
The following NEW packages will be installed:
  wireguard wireguard-tools
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 84.4 kB of archives.
After this operation, 302 kB of additional disk space will be used.
Get:1 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf wireguard-tools armhf 1.0.20210223-1 [76.2 kB]
Get:2 http://mirror.netcologne.de/raspbian/raspbian bullseye/main armhf wireguard all 1.0.20210223-1 [8,164 B]
Fetched 84.4 kB in 5s (15.8 kB/s)
Selecting previously unselected package wireguard-tools.
(Reading database ... 55467 files and directories currently installed.)
Preparing to unpack .../wireguard-tools_1.0.20210223-1_armhf.deb ...
Unpacking wireguard-tools (1.0.20210223-1) ...
Selecting previously unselected package wireguard.
Preparing to unpack .../wireguard_1.0.20210223-1_all.deb ...
Unpacking wireguard (1.0.20210223-1) ...
Setting up wireguard-tools (1.0.20210223-1) ...
wg-quick.target is a disabled or a static unit, not starting it.
Setting up wireguard (1.0.20210223-1) ...
Processing triggers for man-db (2.9.4-2) ...
Updating FireMotD available updates count ...
Enabling wg-quick@wg0
Created symlink /etc/systemd/system/multi-user.target.wants/wg-quick@wg0.service → /lib/systemd/system/wg-quick@.service.
Enabling WireGuard management option
[ ✓ ok ]
RaspAP Install: Adding raspap.sudoers to /etc/sudoers.d/090_raspap
RaspAP Install: Symlinked wpa_supplicant hooks for multiple wlan interfaces
RaspAP Install: Unmasking and enabling hostapd service
Removed /etc/systemd/system/hostapd.service.
Synchronizing state of hostapd.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable hostapd
[ ✓ ok ]
RaspAP Install: Installation completed
Join RaspAP Insiders for early access to exclusive features!

> https://docs.raspap.com/insiders/
> https://github.com/sponsors/RaspAP/

The system needs to be rebooted as a final step. Reboot now? [y/N]:
Raspberry 4, Rev.1.2b, 4GB, Openhab 2.5.12 (OH3 kommt im Winter dran:-))

Benutzeravatar
udo1toni
Beiträge: 15265
Registriert: 11. Apr 2018 18:05
Answers: 245
Wohnort: Darmstadt

Re: Docker für Wireguard Gateway vorher/nachher?

Beitrag von udo1toni »

Man kann vieles machen, ob das eine gute Idee ist, steht aber auf einem anderen Blatt.
openHABian bringt, wenn ich mich richtig erinnere, ebenfalls eine Option mit, Wireguard zu installieren. Es ist aber grundsätzlich keine gute Idee, einen Raspberry auch nur mit einem einzigen Port offen ins Netz zu hängen, es sei denn, das System ist extra dafür ausgelegt. Ich glaube nicht, dass Raspberry Pi OS da ernsthaft auch nur einen Teil der Kriterien gut erfüllt.

Ansonsten muss man nicht viel tun, um openHAB per Docker einzurichten. Normal reicht es, Raspberry Pi OS lite zu installieren, einmal per sudp apt update && sudo apt -y full-upgrade auf den aktuellen Stand zu bringen und anschließend curl -fsSL https://get.docker.com | sh auszuführen. Kann sein, dass curl zuerst mit sudo apt install curl nachinstalliert werden muss...

Es gibt meines Wissens mit Hypriot OS sogar ein spezielles OS für den Raspberry, welches dann schon Docker mit bringt.

Anschließend muss man lediglich in DockerHub die gewünschten Container heraussuchen und einrichten, z.B. hier https://hub.docker.com/r/openhab/openhab erläutert (direkter Link ist leider gerade defekt... schau nach "running from compose file yml"
Du kopierst einfach den Inhalt des compose file nach docker-compose.yml und führst docker-compose aus, den Rest erledigt Docker für Dich.
Portainer ist übrigens auch nett, das dient der grafischen Administration von Docker (natürlich in einem Docker Container eingerichtet...)
gleiches gilt für Samba, Mosquitto und andere Komponenten, die Du vielleicht haben möchtest. openHABian macht das auch nicht anders, nur halt ohne Docker Unterbau. Natürlich gibt es ein paar kniffligere Punkte, wie z.B. das Freigeben der Konfigurationsdateien, weil dazu Volumes geteilt werden müssen. das ist aber auch alle hier erklärt: https://community.openhab.org/t/running ... cker/14267
openHAB4.3.5 stable in einem Debian-Container (bookworm) (Proxmox 8.4.1, LXC), mit openHABian eingerichtet

Antworten