diff --git a/ci/setup_spack.sh b/ci/setup_spack.sh
index 77ed70da9be49c7f93b14a6ef397c1eac1361d88..14f14482a4ea7b9f70fd6e74396a2abf6b56a684 100755
--- a/ci/setup_spack.sh
+++ b/ci/setup_spack.sh
@@ -74,20 +74,14 @@ do
   done
 done
 
-echo "config:" > ${SPACK_SYSTEM_CONFIG_PATH}/config_stack.yaml
 if [ -d cp -r "${STACK_CONFIG_PATH}/templates" ${SPACK_SYSTEM_CONFIG_PATH} ]
 then
-   cp -r "${STACK_CONFIG_PATH}/templates" ${SPACK_SYSTEM_CONFIG_PATH}
-   cat <<EOF >> ${SPACK_SYSTEM_CONFIG_PATH}/config_stack.yaml
-  template_dirs:
-    - ${SPACK_SYSTEM_CONFIG_PATH}/templates
-EOF
+   cp -r "${STACK_CONFIG_PATH}/templates" ${STACK_LOCATION}/spack/share/spack
 fi
 
 if [ -d "${STACK_CONFIG_PATH}/licenses" ]
 then
-  cp -r "${STACK_CONFIG_PATH}/licenses" ${SPACK_SYSTEM_CONFIG_PATH}
-  echo "  license_dir: ${SPACK_SYSTEM_CONFIG_PATH}/licenses" >> ${SPACK_SYSTEM_CONFIG_PATH}/config_stack.yaml
+  cp -r "${STACK_CONFIG_PATH}/licenses/*" ${STACK_LOCATION}/spack/etc/spack
 fi
 
 
diff --git a/stacks/pinot-noir/spack.yaml b/stacks/pinot-noir/spack.yaml
index f0711511126851b53297af12a93016c0cd59e096..61e31e103ab02377872aa3636a89fb54e81a77b2 100644
--- a/stacks/pinot-noir/spack.yaml
+++ b/stacks/pinot-noir/spack.yaml
@@ -14,8 +14,6 @@ spack:
       - definitions_accel.yaml
       - definitions_env.yaml
 
-      - config_stack.yaml
-
   modules:
     default:
       lmod:
diff --git a/stacks/pinot-noir/spack_aocc.yaml b/stacks/pinot-noir/spack_aocc.yaml
index 6c06780bf1836d29d048ffb55ef7b84e78341720..b6e7276c6afff30eae898e3e7019f55dd6525050 100644
--- a/stacks/pinot-noir/spack_aocc.yaml
+++ b/stacks/pinot-noir/spack_aocc.yaml
@@ -14,8 +14,6 @@ spack:
       - definitions_env.yaml
       - definitions_stack.yaml
 
-      - config_stack.yaml
-
   modules:
     default:
       lmod:
diff --git a/stacks/pinot-noir/spack_nvhpc.yaml b/stacks/pinot-noir/spack_nvhpc.yaml
index f3b87b8446888a8bcdd13051b407112b510a72b8..8f5e962e2e962ac4afec6bd1ca18c282c8994936 100644
--- a/stacks/pinot-noir/spack_nvhpc.yaml
+++ b/stacks/pinot-noir/spack_nvhpc.yaml
@@ -14,8 +14,6 @@ spack:
       - definitions_env.yaml
       - definitions_stack.yaml
 
-      - config_stack.yaml
-
   modules:
     default:
       lmod:
diff --git a/stacks/pinot-noir/spack_oneapi.yaml b/stacks/pinot-noir/spack_oneapi.yaml
index 757d1df840a3ca5469ac3522fe999509a1283093..67f92a44c1545928e22ff099f7e20561f34a1842 100644
--- a/stacks/pinot-noir/spack_oneapi.yaml
+++ b/stacks/pinot-noir/spack_oneapi.yaml
@@ -14,8 +14,6 @@ spack:
       - definitions_env.yaml
       - definitions_stack.yaml
 
-      - config_stack.yaml
-
   modules:
     default:
       lmod: