|
|
|
|
@ -119,16 +119,19 @@ EOM
|
|
|
|
|
echo " ${fpr_list[${ind_2nd_last}]}"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
# UPDATE SOPS CONFIG
|
|
|
|
|
# TODO: remove the 'pushd;popd' workaround and make the functions aware of the dir being read
|
|
|
|
|
pushd "${keyfiles_dir}" > /dev/null 2>&1
|
|
|
|
|
# BEGIN
|
|
|
|
|
if [[ "${opt_list_roles}" -eq 1 ]]; then
|
|
|
|
|
# list available roles and exit
|
|
|
|
|
pushd "${roles_def_dir}" > /dev/null 2>&1
|
|
|
|
|
>&2 echo "# INFO: listing roles"
|
|
|
|
|
ls -1d *
|
|
|
|
|
exit 0
|
|
|
|
|
popd > /dev/null 2>&1
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
# UPDATE SOPS CONFIG
|
|
|
|
|
# TODO: remove the 'pushd;popd' workaround and make the functions aware of the dir being read
|
|
|
|
|
pushd "${keyfiles_dir}" > /dev/null 2>&1
|
|
|
|
|
(fn_update_sops_config) > "${sops_config}"
|
|
|
|
|
popd > /dev/null 2>&1
|
|
|
|
|
|
|
|
|
|
|