Applicable to:
- SolusVM
Question
How to update the SSL certificate for SolusVM every 3 months automatically?
Answer
- Connect to Master node via SSH
- Create a bash script for updating certificate
# echo -e "#/bin/bash\n/root/.acme.sh/acme.sh --renew -d example.com --force\ncat /usr/local/svmstack/nginx/ssl/ssl.crt /usr/local/svmstack/nginx/ssl/ssl.key > /usr/local/solusvm/includes/nvnc/cert.pem\nservice svmstack-nginx restart" > /root/upd_ssl.sh
- Make it executable:
# chmod +x /root/upd_ssl.sh
- Add this script to the crone task for regular execution every month:
# { crontab -l; echo "0 0 3 * * /root/upd_ssl.sh "; } | crontab -
Note: The path to script /root/upd_ssl.sh can be different
Comments
0 commentsPlease sign in to leave a comment.