How to Update Node

1. Use NPM to Update Your Node Version To update Node with NPM, you will install the n package, which will be used to interactively manage node versions on your device. Here are the steps: Clear the NPM cache When you install dependencies, some modules are cached to improve the speed of installation in subsequent downloads. So weiterlesen…

renewal-hooks let’s encrypt

/etc/letsencrypt/renewal-hooks/post/001-restart-cockpit.sh !/usr/bin/env bash echo „SSL certificates renewed“ cp /etc/letsencrypt/live/au.hg-system.com/fullchain.pem /etc/cockpit/ws-certs.d/au.hg-system.com.crtcp /etc/letsencrypt/live/au.hg-system.com/privkey.pem /etc/cockpit/ws-certs.d/au.hg-system.com.keychown cockpit-ws:cockpit-ws /etc/cockpit/ws-certs.d/au.hg-system.com.crt /etc/cockpit/ws-certs.d/au.hg-system.com.key echo „Restarting Cockpit“systemctl restart cockpit

Fehlschlag beim Auflösen von »archive.ubuntu.com«

sudo apt update: „Temporärer Fehlschlag beim Auflösen“ / DNS-ProblemTemporärer Fehlschlag beim Auflösen von »archive.ubuntu.com« sudo nano /etc/systemd/resolved.conf add this lines: [Resolve]DNS=8.8.8.8FallbackDNS=8.8.4.4 restart systemd relover: sudo systemctl daemon-reloadsudo systemctl restart systemd-resolved

Unattended Upgrade

sudo apt update && sudo apt upgrade sudo reboot sudo apt install unattended-upgrades apt-listchanges bsd-mailx sudo dpkg-reconfigure -plow unattended-upgrades Configure automatic updates, enter:sudo vi /etc/apt/apt.conf.d/50unattended-upgradesSet up alert email ID:Unattended-Upgrade::Mail „root@hg-system.com“;Automatically reboot Ubuntu box WITHOUT CONFIRMATION for kernel updates:Unattended-Upgrade::Automatic-Reboot „true“;Finally edit the /etc/apt/listchanges.conf and set email ID:email_address=root@hg-system.com

echo <<<EOLThis is outputAnd this is a new lineblah blah blah and this following $var will actually say Howdy as well and now the output endsEOL;

Mails über eigenen Server mit TLS Verschlüsselung

sudo apt install sendmailhostnamectl set-hostname myhostname.com sudo nano /etc/hosts127.0.0.1 localhost myhostname.comsudo sendmailconfig confirm all mit y for yes sudo service nginx restart lokaler test: sendmail -v someone@email.com From: you@yourdomain.comSubject: This is the subject field of the emailThis is the message to be sent.. sudo nano /etc/php/7.4/fpm/php.ini strg + wsendmail sendmail_path= /usr/sbin/sendmail -t -i sudo service weiterlesen…

Reset MySQL password

´´$ sudo systemctl stop mysql$ sudo mkdir -p /var/run/mysqld$ sudo chown mysql:mysql /var/run/mysqld$ sudo /usr/sbin/mysqld –skip-grant-tables –skip-networking & FLUSH PRIVILEGES;USE mysql;update user set plugin=“mysql_native_password“;ALTER USER ‚root’@’localhost‘ IDENTIFIED BY ‚N3w_p@ssw0rD.‘;quit !fix! error: plugin ‚auth_socket‘ is not loaded !fix! mysql root passwort does not work