Commit 91c0eec3 authored by Alain Takoudjou's avatar Alain Takoudjou

resilient stack: fix promise for checking public key content

parent bf16d268
...@@ -31,7 +31,7 @@ md5sum = 85e777bd349a5c881d36e747882aee8a ...@@ -31,7 +31,7 @@ md5sum = 85e777bd349a5c881d36e747882aee8a
[template-replicated] [template-replicated]
filename = template-replicated.cfg.in filename = template-replicated.cfg.in
md5sum = 55ef107f499e5e604b8d277098618fed md5sum = 5369b039600e1df8b471ac4b41d5de60
[template-parts] [template-parts]
filename = template-parts.cfg.in filename = template-parts.cfg.in
......
...@@ -140,8 +140,8 @@ takeover-{{namebase}}-{{id}}-password = ${request-{{namebase}}-pseudo-replicatin ...@@ -140,8 +140,8 @@ takeover-{{namebase}}-{{id}}-password = ${request-{{namebase}}-pseudo-replicatin
# XXX: maybe we should consider empty values to be non-nexistent. # XXX: maybe we should consider empty values to be non-nexistent.
recipe = collective.recipe.template recipe = collective.recipe.template
# XXX: don't use system executable # XXX: don't use system executable
input = inline:#!/bin/sh input = inline:#!/bin/bash
PUBLIC_KEY_CONTENT="${request-{{namebase}}:connection-ssh-public-key})" PUBLIC_KEY_CONTENT="${request-{{namebase}}:connection-ssh-public-key}"
if [[ ! -n "$PUBLIC_KEY_CONTENT" || "$PUBLIC_KEY_CONTENT" == *None* ]]; then if [[ ! -n "$PUBLIC_KEY_CONTENT" || "$PUBLIC_KEY_CONTENT" == *None* ]]; then
exit 1 exit 1
fi fi
...@@ -155,8 +155,8 @@ mode = 700 ...@@ -155,8 +155,8 @@ mode = 700
# XXX: maybe we should consider empty values to be non-nexistent. # XXX: maybe we should consider empty values to be non-nexistent.
recipe = collective.recipe.template recipe = collective.recipe.template
# XXX: don't use system executable # XXX: don't use system executable
input = inline:#!/bin/sh input = inline:#!/bin/bash
PUBLIC_KEY_CONTENT="${request-{{namebase}}-pseudo-replicating-{{id}}:connection-ssh-public-key})" PUBLIC_KEY_CONTENT="${request-{{namebase}}-pseudo-replicating-{{id}}:connection-ssh-public-key}"
if [[ ! -n "$PUBLIC_KEY_CONTENT" || "$PUBLIC_KEY_CONTENT" == *None* ]]; then if [[ ! -n "$PUBLIC_KEY_CONTENT" || "$PUBLIC_KEY_CONTENT" == *None* ]]; then
exit 1 exit 1
fi fi
...@@ -217,8 +217,8 @@ sla-{{ key }} = {{ value }} ...@@ -217,8 +217,8 @@ sla-{{ key }} = {{ value }}
# XXX: maybe we should consider empty values to be non-nexistent. # XXX: maybe we should consider empty values to be non-nexistent.
recipe = collective.recipe.template recipe = collective.recipe.template
# XXX: don't use system executable # XXX: don't use system executable
input = inline:#!/bin/sh input = inline:#!/bin/bash
PUBLIC_KEY_CONTENT="${request-pbs-{{namebase}}-{{id}}:connection-ssh-key}:connection-ssh-key})" PUBLIC_KEY_CONTENT="${request-pbs-{{namebase}}-{{id}}:connection-ssh-key}"
if [[ ! -n "$PUBLIC_KEY_CONTENT" || "$PUBLIC_KEY_CONTENT" == *None* ]]; then if [[ ! -n "$PUBLIC_KEY_CONTENT" || "$PUBLIC_KEY_CONTENT" == *None* ]]; then
exit 1 exit 1
fi fi
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment