From 93cea88ae6e9eee76e9a777d67cb94f406acb97d Mon Sep 17 00:00:00 2001 From: hms Date: Wed, 3 Feb 2021 15:37:35 -0800 Subject: [PATCH] datetime fix --- update-NebulaNodeCert | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/update-NebulaNodeCert b/update-NebulaNodeCert index 3fb753a..083710e 100644 --- a/update-NebulaNodeCert +++ b/update-NebulaNodeCert @@ -29,9 +29,11 @@ if [[ -n $1 ]]; then exit fi -DATETIME=$(date '%(%Y%m%d-%H%M%S)T\n' -1) +DATETIME=$(date '+%Y%m%d-%H%M%S') NODENAME=$(${NEBULACERTBINPATH} print -path ${CERTPATH} -json | jq -s .[].details.name | sed 's/["]//g') +#### TO-DO #### +# Make NODEIPS an Array like NODEGROUPS NODEIPS=$(${NEBULACERTBINPATH} print -path ${CERTPATH} -json | jq -s --compact-output .[].details.ips | sed 's/[]["]//g') NODEGROUPS=($(${NEBULACERTBINPATH} print -path ${CERTPATH} -json | jq -s --compact-output .[].details.groups | sed 's/[]["]//g' | sed 's/,/ /g')) CERTISCASTATUS=$(${NEBULACERTBINPATH} print -path ${CERTPATH} -json | jq -s --compact-output .[].details.isCa)