test local clone
Some checks failed
Build and Deploy Container / build_and_deploy (push) Failing after 19s

This commit is contained in:
Clemens Hering
2025-11-09 16:23:36 +01:00
parent 8336d9c19b
commit 38b486ab2c

View File

@@ -19,6 +19,24 @@ jobs:
build_and_deploy: build_and_deploy:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Pre-clean Git global config (avoid https→ssh rewrite)
shell: bash
run: |
set -euo pipefail
git --version || true
echo "Global git config before:" || true
git config --global --list || true
# Remove any url.*.insteadof rules that force SSH for gitea.smb-corp.de
for key in $(git config --global --get-regexp '^url\\..*\\.insteadof$' 2>/dev/null | awk '{print $1}'); do
if echo "$key" | grep -qi 'gitea\\.smb-corp\\.de'; then
echo "Removing global mapping: $key"
git config --global --unset-all "$key" || true
fi
done
# Ensure no global sshCommand forces SSH
git config --global --unset-all core.sshCommand || true
echo "Global git config after:" || true
git config --global --list || true
- name: Setup SSH for git/scp/rsync - name: Setup SSH for git/scp/rsync
shell: bash shell: bash
run: | run: |
@@ -30,7 +48,6 @@ jobs:
# Ensure host keys are present to avoid interactive prompts # Ensure host keys are present to avoid interactive prompts
(ssh-keygen -F "$TARGET_HOST" >/dev/null || ssh-keyscan -H "$TARGET_HOST" >> ~/.ssh/known_hosts) || true (ssh-keygen -F "$TARGET_HOST" >/dev/null || ssh-keyscan -H "$TARGET_HOST" >> ~/.ssh/known_hosts) || true
(ssh-keygen -F gitea.smb-corp.de >/dev/null || ssh-keyscan -H gitea.smb-corp.de >> ~/.ssh/known_hosts) || true (ssh-keygen -F gitea.smb-corp.de >/dev/null || ssh-keyscan -H gitea.smb-corp.de >> ~/.ssh/known_hosts) || true
git config --global url."ssh://git@gitea.smb-corp.de".insteadOf "https://gitea.smb-corp.de"
- name: Checkout Repository - name: Checkout Repository
uses: actions/checkout@v4 uses: actions/checkout@v4