Something it seems a lot of people don’t know is that you can run commands on a remote system using ssh
. The syntax is simple enough, just ssh user@host command
. So if you wanted to script copying a cert to a remote host, and then restart the web server, your script might have a few scp
commands, followed by ssh root@neth-backup systemctl reload httpd
.
Edit: which I see is used in the comment above mine, but thought it was worth making explicit.