Old Commands
Just some commands I used to use routinely, saving here because I'm bound to need it all again
Gemini Related
Generate Gemini Server Cert
openssl req -x509 -newkey rsa:4096 -keyout od_key.pem -out od_cert.pem -days 365 -nodes -subj '/CN=oppen.digital'
Open port 1965 on Debian
iptables -I INPUT 1 -i eth0 -p tcp --dport 1965 -j ACCEPT
Exit stale SSH Session
type enter ~.
Image Resize
ImageMagick:
# Resize based on width, maintaining aspect ratio
convert image.jpg -resize 1280 image.jpg
# Convert from one format to another:
convert image.jpg image.png
# Rotate:
convert image.png -rotate 90 image.png
PM2
Process Manager 2:
pm2 list - lists current managed processes
pm2 monit - nice dashboard including logs
pm2 restart id - restart a process
pm2 logs - display logs
pm2 flush - delete all logs