feat : correctif mineur
This commit is contained in:
@@ -295,11 +295,11 @@ mkdir -p \"\$(dirname \"\$REPO_DIR\")\"
|
|||||||
|
|
||||||
if [[ ! -d \"\$CLONE_DIR/.git\" ]]; then
|
if [[ ! -d \"\$CLONE_DIR/.git\" ]]; then
|
||||||
rm -rf \"\$CLONE_DIR\"
|
rm -rf \"\$CLONE_DIR\"
|
||||||
git clone --branch \"\$REPO_BRANCH\" --single-branch \"\$REPO_URL\" \"\$CLONE_DIR\"
|
git clone --branch \"\$REPO_BRANCH\" --single-branch \"\$REPO_URL\" \"\$CLONE_DIR\" >/dev/null 2>&1
|
||||||
else
|
else
|
||||||
git -C \"\$CLONE_DIR\" fetch --prune origin
|
git -C \"\$CLONE_DIR\" fetch --prune origin >/dev/null 2>&1
|
||||||
git -C \"\$CLONE_DIR\" checkout -f \"\$REPO_BRANCH\"
|
git -C \"\$CLONE_DIR\" checkout -f \"\$REPO_BRANCH\" >/dev/null 2>&1
|
||||||
git -C \"\$CLONE_DIR\" reset --hard \"origin/\$REPO_BRANCH\"
|
git -C \"\$CLONE_DIR\" reset --hard \"origin/\$REPO_BRANCH\" >/dev/null 2>&1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
[[ -f \"\$CORE_SCRIPT\" ]] || { echo '{\"status\":\"error\",\"message\":\"script core introuvable sur la cible\"}'; exit 1; }
|
[[ -f \"\$CORE_SCRIPT\" ]] || { echo '{\"status\":\"error\",\"message\":\"script core introuvable sur la cible\"}'; exit 1; }
|
||||||
@@ -355,7 +355,10 @@ with open(sys.argv[1], 'r', encoding='utf-8') as f:
|
|||||||
data = json.load(f)
|
data = json.load(f)
|
||||||
print(data.get("status", "error"))
|
print(data.get("status", "error"))
|
||||||
PY
|
PY
|
||||||
)"
|
)" || {
|
||||||
|
cat "$REMOTE_RESULT_JSON" 2>/dev/null || true
|
||||||
|
fail "réponse JSON invalide renvoyée par la cible ${TARGET}"
|
||||||
|
}
|
||||||
|
|
||||||
if [[ "$REMOTE_STATUS" != "success" ]]; then
|
if [[ "$REMOTE_STATUS" != "success" ]]; then
|
||||||
cat "$REMOTE_RESULT_JSON"
|
cat "$REMOTE_RESULT_JSON"
|
||||||
|
|||||||
Reference in New Issue
Block a user