From 3bb9f15061e7ae4ddb4b551253b6afe42b68e8a6 Mon Sep 17 00:00:00 2001 From: hishamanver <45935550+hishamanver@users.noreply.github.com> Date: Sat, 14 Nov 2020 19:50:58 +1100 Subject: [PATCH] add ca_srl creation when custom cert and key are provided (#65) Co-authored-by: Hisham Anver --- create_ca_cert.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/create_ca_cert.sh b/create_ca_cert.sh index 56ad721..4ae134b 100644 --- a/create_ca_cert.sh +++ b/create_ca_cert.sh @@ -31,6 +31,9 @@ CA_SRL_FILE=/ca/ca.srl if [ -f "$CA_CRT_FILE" ] ; then logInfo "CA already exists. Good. We'll reuse it." + if [ ! -f "$CA_SRL_FILE" ] ; then + echo 01 > ${CA_SRL_FILE} + fi else logInfo "No CA was found. Generating one." logInfo "*** Please *** make sure to mount /ca as a volume -- if not, everytime this container starts, it will regenerate the CA and nothing will work."