diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index d62de6b097c950cab9ee54676276906d2eb21680..99797be7745a0dcc7a9e42714b7ac7a113074681 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -2,36 +2,40 @@ image: eicweb.phy.anl.gov:4567/eic/juggler/juggler:$JUGGLER_TAG
 
 default:
   artifacts:
-    expire_in: 120 mins
+    expire_in: 72 hours 
     paths:
       - results/
-      - datasets/
-      - sim_output/
-      - data
+      - images/
         #    exclude:
         #      - .git/
         #      - datasets/.git/
-  before_script:
-    - git clone https://eicweb.phy.anl.gov/EIC/NPDet.git
-    - git clone https://eicweb.phy.anl.gov/EIC/detectors/topside.git && mkdir topside/build && cd topside/build && cmake ../. -DCMAKE_INSTALL_PREFIX=/usr/local && make -j20 install && cd ../..
+        #before_script:
+        #  - git clone https://eicweb.phy.anl.gov/EIC/NPDet.git
+        #  - git clone https://eicweb.phy.anl.gov/EIC/detectors/topside.git && mkdir topside/build && cd topside/build && cmake ../. -DCMAKE_INSTALL_PREFIX=/usr/local && make -j20 install && cd ../..
         #    - cd NPDet/build && cmake ../. -DCMAKE_INSTALL_PREFIX=/usr/local && make -j10 && make install
 
 stages:
+  - config
   - initialize
   - data_init
   - simulate
   - benchmarks
   - deploy
-    #- others
+
+env:
+  stage: config
+  script:
+    - ./util/print_env.sh
+    - mkdir -p /scratch/${CI_PROJECT_NAME}_${CI_PIPELINE_ID}
 
 detector:
   stage: initialize
-  needs: []
+  needs: ["env"]
   timeout: 1 hours
   cache:
     key:
       files:
-        - config/env.sh
+        - options/env.sh
         - util/build_detector.sh
       prefix: "$CI_COMMIT_REF_SLUG"
     paths:
diff --git a/options/env.sh b/options/env.sh
index bf20ba41020c4b9d91f9d8e6d87a7d1a7ff6f52a..c392e51d1eeacd885df0eb619274cefbcb7b3ecb 100755
--- a/options/env.sh
+++ b/options/env.sh
@@ -68,6 +68,12 @@ fi
 export JUGGLER_INSTALL_PREFIX=`realpath ${JUGGLER_INSTALL_PREFIX}`
 
 
+## Location of local data for pass data from job to job within pipeline.
+## Not saved as artifacts.
+if [ ! -n  "${LOCAL_DATA_PATH}" ] ; then 
+  LOCAL_DATA_PATH="/scratch/${CI_PROJECT_NAME}_${CI_PIPLINE_ID}"
+fi
+
 ## =============================================================================
 ## Other utility variables that govern how some of the dependent packages
 ## are built and installed. You should not have to change these.
@@ -94,6 +100,7 @@ echo "JUGGLER_N_EVENTS:           ${JUGGLER_N_EVENTS}"
 echo "JUGGLER_N_THREADS:          ${JUGGLER_N_THREADS}"
 echo "JUGGLER_RNG_SEED:           ${JUGGLER_RNG_SEED}"
 echo "JUGGLER_INSTALL_PREFIX:     ${JUGGLER_INSTALL_PREFIX}"
+echo "LOCAL_DATA_PATH:            ${LOCAL_DATA_PATH}"
 echo "LOCAL_PREFIX:               ${LOCAL_PREFIX}"
 echo "DETECTOR_PREFIX:            ${DETECTOR_PREFIX}"
 echo "DETECTOR_PATH:              ${DETECTOR_PATH}"
diff --git a/util/print_env.sh b/util/print_env.sh
index ce4010509e8763b3dba0fdc93bf0b6584f172e27..7a4a8935ca7a8ad4262830af5f3ecbd8c76a6117 100755
--- a/util/print_env.sh
+++ b/util/print_env.sh
@@ -7,6 +7,7 @@ echo "JUGGLER_N_EVENTS:           ${JUGGLER_N_EVENTS}"
 echo "JUGGLER_N_THREADS:          ${JUGGLER_N_THREADS}"
 echo "JUGGLER_RNG_SEED:           ${JUGGLER_RNG_SEED}"
 echo "JUGGLER_INSTALL_PREFIX:     ${JUGGLER_INSTALL_PREFIX}"
+echo "LOCAL_DATA_PATH:            ${LOCAL_DATA_PATH}"
 echo "LOCAL_PREFIX:               ${LOCAL_PREFIX}"
 echo "DETECTOR_PREFIX:            ${DETECTOR_PREFIX}"
 echo "DETECTOR_PATH:              ${DETECTOR_PATH}"