This commit is contained in:
Cory Hawkless 2020-08-25 20:07:33 +09:30
parent 85ce1c62c9
commit d5b1958a43
1 changed files with 4 additions and 1 deletions

View File

@ -12,8 +12,11 @@ $VAULT_ADDR/v1/rootca_store/issue/{{vaultStoreName}} > certificateResult.txt
jq .data.private_key certificateResult.txt | sed "s/\"//g" | sed "s/\\\n/\n/g" > cert.pem
jq .data.certificate certificateResult.txt | sed "s/\"//g" | sed "s/\\\n/\n/g" > cert.crt
jq .data.issuing_ca certificateResult.txt | sed "s/\"//g" | sed "s/\\\n/\n/g" > ca.crt
mv cert.pem /etc/ssl/private/$(hostname).{{local_domainname}}.key
mv cert.crt /etc/ssl/certs/$(hostname).{{local_domainname}}.crt
mv ca.crt /etc/ssl/certs/{{local_domainname}}-CA.crt
rm certificateResult.txt
#rm certificateResult.txt