This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| dpkg --print-architecture # amd64 | |
| uname -m # x86_64 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Control which monitor the login screen appears on | |
| sudo cp ~/.config/monitors.xml /var/lib/gdm3/.config/ && sudo chown gdm:gdm /var/lib/gdm3/.config/monitors.xml |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| curl -4 https://ipecho.net/plain; echo |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ssh-keygen -t ed25519 -C "EMAIL HERE" | |
| eval "$(ssh-agent -s)" | |
| ssh-add ~/.ssh/KEY_NAME |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| network: | |
| version: 2 | |
| renderer: NetworkManager | |
| ethernets: | |
| enp4s0: | |
| dhcp4: no | |
| addresses: [10.2.2.3/24] | |
| routes: | |
| - to: default | |
| via: 192.168.1.1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # MAC | |
| ip l show dev eth0 | grep -o -E ..:..:..:..:..:.. | head -n 1 | |
| # IP | |
| ip a show dev eth0 | grep -o -P "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}(?=\/)" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [Unit] | |
| Description=Service Name | |
| [Service] | |
| ExecStart=/bin/bash -c "" | |
| Restart=always | |
| [Install] | |
| WantedBy=multi-user.target |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| From https://forums.raspberrypi.com/viewtopic.php?t=175161#p1117946 | |
| Add to /boot/config.txt | |
| dtoverlay=gpio-poweroff,gpiopin=4,active_low |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| country=gb | |
| update_config=1 | |
| ctrl_interface=/var/run/wpa_supplicant | |
| network={ | |
| scan_ssid=1 | |
| ssid="" | |
| psk="" | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # -p - ports to check | |
| # -oG output in grep-able format | |
| sudo nmap 192.168.0.0/24 -p 22 -oG - | awk '$5 ~ /open/ {print $2}' |