From 5648e171e42df8c97ce2d6c16e00fce43cf08141 Mon Sep 17 00:00:00 2001 From: Mark Calvert Date: Tue, 23 Jan 2024 09:53:57 +1300 Subject: [PATCH] Set xloader api token in ckan.ini --- ckan/docker-entrypoint.d/02_setup_dbca.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/ckan/docker-entrypoint.d/02_setup_dbca.sh b/ckan/docker-entrypoint.d/02_setup_dbca.sh index 2e3f5158..7176537b 100644 --- a/ckan/docker-entrypoint.d/02_setup_dbca.sh +++ b/ckan/docker-entrypoint.d/02_setup_dbca.sh @@ -5,6 +5,7 @@ CKAN__PLUGINS=$(grep '^ckan\.plugins' $APP_DIR/config/dbca.ini | cut -d'=' -f2) echo "CKAN__PLUGINS: $CKAN__PLUGINS" if [[ $CKAN__PLUGINS == *"xloader"* ]]; then + CKAN_INI=$APP_DIR/ckan.ini # Add ckan.xloader.api_token to the CKAN config file (updated with corrected value later) echo "Setting a temporary value for ckanext.xloader.api_token" ckan config-tool $CKAN_INI "ckanext.xloader.api_token=$(ckan -c $CKAN_INI user token add $CKAN_SYSADMIN_NAME xloader | tail -n 1 | tr -d '\t')"