From 8b0927a06e1c7f49ceec346fcfe6733f95176e50 Mon Sep 17 00:00:00 2001 From: Scott Koranda Date: Mon, 12 Jun 2017 14:56:09 -0500 Subject: [PATCH] Better handling of injected MetadataProvider SHIBBOLETH_SP_METADATA_PROVIDER_XML may still be injected using the _FILE approach but it is handled uniquely now to prevent an error message from the bash declare command caused by the contents of the file usually containing special characters. Fundamentally this is caused by the left and right-hand sides of declare "${config_var}"=`cat $file_name` being evaluated before the actual 'declare' command is evaluated. --- .../docker-comanage-shibboleth-sp-entrypoint | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/comanage-registry-shibboleth-sp/docker-comanage-shibboleth-sp-entrypoint b/comanage-registry-shibboleth-sp/docker-comanage-shibboleth-sp-entrypoint index edc2175..868846b 100755 --- a/comanage-registry-shibboleth-sp/docker-comanage-shibboleth-sp-entrypoint +++ b/comanage-registry-shibboleth-sp/docker-comanage-shibboleth-sp-entrypoint @@ -28,13 +28,16 @@ fi # Configuration details that may be injected through environment # variables or the contents of files. +# +# SHIBBOLETH_SP_METADATA_PROVIDER_XML may also be injected in the +# same way but because of the presence of special characters in the +# XML it is handled differently. injectable_config_vars=( SHIBBOLETH_SP_ENTITY_ID SHIBBOLETH_SP_CERT SHIBBOLETH_SP_PRIVKEY SHIBBOLETH_SP_SAMLDS_URL - SHIBBOLETH_SP_METADATA_PROVIDER_XML ) # If the file associated with a configuration variable is present then