diff --git a/cm.sh b/cm.sh index 97776b816e298e01bc94fd103ef47135f48bfd3f..4d86836cd8f8c9a0ef9c39da803ec27fed322583 100755 --- a/cm.sh +++ b/cm.sh @@ -16,6 +16,7 @@ # 2021-02-10 <axel.hahn@iml.unibe.ch> compare hashes, logging # 2021-02-12 <axel.hahn@iml.unibe.ch> added self test # 2021-02-17 <axel.hahn@iml.unibe.ch> ensure checks list of aliases; new: optional host filter before adding a cert +# 2021-03-12 <axel.hahn@iml.unibe.ch> create file for haproxy # ====================================================================== @@ -102,6 +103,9 @@ function _certTransfer(){ _wd "--- copy key to ${CM_dircerts}" cp ${CM_filekey} ${CM_outfile_key} + _wd "--- create chained file for haproxy" + cat ${CM_outfile_cert} ${CM_outfile_key} > ${CM_outfile_haproxy} + _wd "--- content of output dir $CM_dircerts:" ls -l $CM_dircerts/* } @@ -239,6 +243,7 @@ function _setenv(){ CM_outfile_cert=${CM_dircerts}/${CM_fqdn}.cert.cer CM_outfile_chain=${CM_dircerts}/${CM_fqdn}.fullchain.cer CM_outfile_key=${CM_dircerts}/${CM_fqdn}.key.pem + CM_outfile_haproxy=${CM_dircerts}/${CM_fqdn}.haproxy.pem CM_outfile_ca=${CM_dircerts}/${CM_fqdn}.ca.cer # echo $CM_fqdn; set | grep "^CM_"; echo