Skip to content
Snippets Groups Projects
Commit d1b4e2bb authored by Wouter Deconinck's avatar Wouter Deconinck
Browse files

Mask deploy tokens in logs

parent e6697931
No related branches found
No related tags found
1 merge request!40Mask deploy tokens in logs
......@@ -36,10 +36,11 @@ fi
echo "Fetching ${JUGGLER_DETECTOR}"
if [ -n "${JUGGLER_DETECTOR_DEPLOY_TOKEN_USERNAME:-}" -a -n "${JUGGLER_DETECTOR_DEPLOY_TOKEN_PASSWORD:-}" ]; then
DEPLOY_TOKEN="${JUGGLER_DETECTOR_DEPLOY_TOKEN_USERNAME}:${JUGGLER_DETECTOR_DEPLOY_TOKEN_PASSWORD}@"
echo "Deploy token for ${JUGGLER_DETECTOR_DEPLOY_TOKEN_USERNAME} is masked in the next line."
else
DEPLOY_TOKEN=""
fi
echo "git clone -b ${JUGGLER_DETECTOR_VERSION} --depth 1 https://${DEPLOY_TOKEN}eicweb.phy.anl.gov/EIC/detectors/${JUGGLER_DETECTOR}.git"
echo "git clone -b ${JUGGLER_DETECTOR_VERSION} --depth 1 https://eicweb.phy.anl.gov/EIC/detectors/${JUGGLER_DETECTOR}.git"
git clone -b ${JUGGLER_DETECTOR_VERSION} --depth 1 https://${DEPLOY_TOKEN}eicweb.phy.anl.gov/EIC/detectors/${JUGGLER_DETECTOR}.git
[[ "$?" == "0" ]] || exit 1
rm -rf "${JUGGLER_DETECTOR}/.git"
......@@ -53,10 +54,11 @@ fi
echo "Fetching ${BEAMLINE_CONFIG}"
if [ -n "${BEAMLINE_CONFIG_DEPLOY_TOKEN_USERNAME:-}" -a -n "${BEAMLINE_CONFIG_DEPLOY_TOKEN_PASSWORD:-}" ]; then
DEPLOY_TOKEN="${BEAMLINE_CONFIG_DEPLOY_TOKEN_USERNAME}:${BEAMLINE_CONFIG_DEPLOY_TOKEN_PASSWORD}@"
echo "Deploy token for ${BEAMLINE_CONFIG_DEPLOY_TOKEN_USERNAME} is masked in the next line."
else
DEPLOY_TOKEN=""
fi
echo "git clone -b ${BEAMLINE_CONFIG_VERSION} --depth 1 https://${DEPLOY_TOKEN}eicweb.phy.anl.gov/EIC/detectors/${BEAMLINE_CONFIG}.git"
echo "git clone -b ${BEAMLINE_CONFIG_VERSION} --depth 1 https://eicweb.phy.anl.gov/EIC/detectors/${BEAMLINE_CONFIG}.git"
git clone -b ${BEAMLINE_CONFIG_VERSION} --depth 1 https://${DEPLOY_TOKEN}eicweb.phy.anl.gov/EIC/detectors/${BEAMLINE_CONFIG}.git
[[ "$?" == "0" ]] || exit 1
rm -rf "${BEAMLINE_CONFIG}/.git"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment