Does anyone have simple security stackscript for ubuntu?
Every time I create a server, I do the same things by hand. It would be great to automate it in some way, but dont know how. I searched through the 800 or so stack scripts for ubuntu, and there are a lot of complex installers for specific products, but I could not find a simple standard one to do the following:
1) apt-get update/upgrade etc.
2) install/configure UWF for only ssh (and posssibly web)
3) install/configure fail2ban
4) create a user for me with sudo and add my certificate.
5) disable passwords.
6) any other standard stuff.
The nearest I could find was this:
https://github.com/nigma/StackScripts/blob/master/123%20-%20lib-system-ubuntu.sh
But it just creates a bunch of functions - there is no instructions on how to actually run it.
I also saw the stackscript with id=1 one has some functions, but I cant see an example of where this is used to set the certificate etc.
Any suggestions.
2 Replies
Taking a look at our public stackscripts, this hardened Ubuntu 16.04 LTS stackscript might get you going in the right direction. I hope this helps!