This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| raspberry_phoscon [2020/12/06 12:41] – herwarth | raspberry_phoscon [2020/12/13 09:50] (current) – herwarth | ||
|---|---|---|---|
| Line 7: | Line 7: | ||
| Use Etcher or whatever to install the downloaded zip on a SD card. | Use Etcher or whatever to install the downloaded zip on a SD card. | ||
| - | ==== Initial settings | + | ==== Initial settings |
| Use raspi-config to set network and change password of the pi user and change the hostname: | Use raspi-config to set network and change password of the pi user and change the hostname: | ||
| < | < | ||
| Line 16: | Line 16: | ||
| systemctl start ssh.service | systemctl start ssh.service | ||
| </ | </ | ||
| + | Disable swap | ||
| + | < | ||
| + | dphys-swapfile swapoff | ||
| + | dphys-swapfile uninstall | ||
| + | systemctl disable dphys-swapfile | ||
| + | </ | ||
| + | Set time | ||
| <code - / | <code - / | ||
| [Time] | [Time] | ||
| Line 24: | Line 31: | ||
| # | # | ||
| </ | </ | ||
| + | ====Install VNC server==== | ||
| + | < | ||
| + | apt install \ | ||
| + | curl \ | ||
| + | kmod \ | ||
| + | libcap2-bin \ | ||
| + | libqt5core5a \ | ||
| + | libqt5gui5 \ | ||
| + | libqt5network5 \ | ||
| + | libqt5serialport5 \ | ||
| + | libqt5sql5 \ | ||
| + | libqt5websockets5 \ | ||
| + | libqt5widgets5 \ | ||
| + | lsof \ | ||
| + | sqlite3 \ | ||
| + | tigervnc-standalone-server \ | ||
| + | tigervnc-common \ | ||
| + | wmii \ | ||
| + | xfonts-base \ | ||
| + | xfonts-scalable | ||
| + | </ | ||
| + | ===Configure VNC=== | ||
| + | <code - / | ||
| + | # Vncserver service file for Debian or Ubuntu with systemd | ||
| + | # | ||
| + | # 1. Copy this file to / | ||
| + | # 2. Edit User= | ||
| + | # e.g " | ||
| + | # 3. Edit the vncserver parameters appropriately in the ExecStart= line! | ||
| + | # e.g. the -localhost option only allows connections from localhost (or via ssh tunnels) | ||
| + | # 4. Run `systemctl daemon-reload` | ||
| + | # 5. Run `systemctl enable vncserver@:< | ||
| + | # | ||
| + | |||
| + | [Unit] | ||
| + | Description=Remote desktop service (VNC) | ||
| + | After=syslog.target network.target | ||
| + | |||
| + | [Service] | ||
| + | Type=forking | ||
| + | User=pi | ||
| + | |||
| + | # Clean any existing files in / | ||
| + | ExecStartPre=/ | ||
| + | ExecStart=/ | ||
| + | ExecStop=/ | ||
| + | |||
| + | [Install] | ||
| + | WantedBy=multi-user.target | ||
| + | </ | ||
| + | <code - / | ||
| + | . | ||
| + | . | ||
| + | -- vncconfig -iconic & | ||
| + | ++ vncconfig -nowin & | ||
| + | . | ||
| + | . | ||
| + | </ | ||
| + | As user pi | ||
| + | < | ||
| + | tigervncpasswd | ||
| + | </ | ||
| + | This creates a .vnc directory in the homedir of user pi with a passwd file in it. This is mandatory for the daemon to load. | ||
| + | < | ||
| + | systemctl daemon-reload | ||
| + | systemctl start vncserver@\: | ||
| + | systemctl enable vncserver@\: | ||
| + | </ | ||
| + | Check with a VNC client if you can connect to the VNC server. | ||
| + | |||
| + | ====Install Phoscon (DeCONZ) software==== | ||
| + | ===Import key=== | ||
| + | < | ||
| + | wget -O - http:// | ||
| + | apt-key add - | ||
| + | </ | ||
| + | |||
| + | ===Install software=== | ||
| + | < | ||
| + | sh -c "echo 'deb http:// | ||
| + | $(lsb_release -cs) main' > \ | ||
| + | / | ||
| + | </ | ||
| + | < | ||
| + | apt update | ||
| + | apt install deconz | ||
| + | </ | ||
| + | ===Enable DeCONZ GUI=== | ||
| + | < | ||
| + | systemctl enable deconz-gui | ||
| + | systemctl start deconz-gui | ||
| + | </ | ||
| + | ====Unattended upgrades==== | ||
| + | I do not want to update manually. | ||
| + | < | ||
| + | apt install unattended-upgrades apt-listchanges | ||
| + | </ | ||
| + | < | ||
| + | cp / | ||
| + | </ | ||
| + | <code - / | ||
| + | . | ||
| + | . | ||
| + | Unattended-Upgrade:: | ||
| + | // Codename based matching: | ||
| + | // This will follow the migration of a release through different | ||
| + | // archives (e.g. from testing to stable and later oldstable). | ||
| + | // Software will be the latest available for the named release, | ||
| + | // but the Debian release itself will not be automatically upgraded. | ||
| + | " | ||
| + | |||
| + | // Archive or Suite based matching: | ||
| + | // Note that this will silently match a different release after | ||
| + | // migration to the specified archive (e.g. testing becomes the | ||
| + | // new stable). | ||
| + | // " | ||
| + | // " | ||
| + | // " | ||
| + | // " | ||
| + | }; | ||
| + | . | ||
| + | . | ||
| + | . | ||
| + | // Remove unused automatically installed kernel-related packages | ||
| + | // (kernel images, kernel headers and kernel version locked tools). | ||
| + | Unattended-Upgrade:: | ||
| + | |||
| + | // Do automatic removal of newly unused dependencies after the upgrade | ||
| + | Unattended-Upgrade:: | ||
| + | |||
| + | // Do automatic removal of unused packages after the upgrade | ||
| + | // (equivalent to apt-get autoremove) | ||
| + | Unattended-Upgrade:: | ||
| + | |||
| + | // Automatically reboot *WITHOUT CONFIRMATION* if | ||
| + | // the file / | ||
| + | Unattended-Upgrade:: | ||
| + | |||
| + | // Automatically reboot even if there are users currently logged in | ||
| + | // when Unattended-Upgrade:: | ||
| + | Unattended-Upgrade:: | ||
| + | |||
| + | // If automatic reboot is enabled and needed, reboot at the specific | ||
| + | // time instead of immediately | ||
| + | // Default: " | ||
| + | Unattended-Upgrade:: | ||
| + | . | ||
| + | . | ||
| + | </ | ||
| + | Test | ||
| + | < | ||
| + | unattended-upgrades -d | ||
| + | </ | ||
| + | This should not give any error | ||
| + | < | ||
| + | dpkg-reconfigure -plow unattended-upgrades | ||
| + | </ | ||
| + | |||
| + | |||
| {{tag> | {{tag> | ||