Completes POCONSOLE-73. Adds renew_certs.sh which will regenerate and move ssl certificates

This commit is contained in:
Patrick McDonagh
2016-11-28 16:16:17 -06:00
parent fbfa9eb91a
commit 446162cfd4
2 changed files with 8 additions and 1 deletions

7
renew_certs.sh Normal file
View File

@@ -0,0 +1,7 @@
#!/bin/bash
mkdir -p /root/ssl
FQDN=$(hostname -f)
openssl req -newkey rsa:2048 -nodes -keyout poconsole.key -x509 -days 365 -out poconsole.crt -subj "/C=US/ST=Texas/L=Dallas/O=Henry Pump/CN=$FQDN"
mv poconsole.key /root/ssl/
mv poconsole.crt /root/ssl/

View File

@@ -1,5 +1,5 @@
#!/bin/bash #!/bin/bash
OLDDIR=$PWD OLDDIR=$PWD
cd /root/www cd /root/www
twistd --pidfile=/root/datalogger.pid web --https=5000 --wsgi app.app -c app/hplumberjack.crt -k app/hplumberjack.key twistd --pidfile=/root/datalogger.pid web --https=5000 --wsgi app.app -c /root/ssl/poconsole.crt -k /root/ssl/poconsole.key
cd $OLDDIR cd $OLDDIR