Linux

Generating self-signed SSL certificates to be used in Nginx #

The same command works on macOS X.

openssl req -x509 -nodes -days 36500 -newkey rsa:2048 \
 -keyout private-selfsigned.key -out public-selfsigned.crt

Automatically confirming a command in Linux #

yes | ./script

In crontab you can do something like:

@monthly yes | ./script

Discovering the sha256 of a file using openssl: #

openssl sha256 OperaSetup.zip