test local clone
Some checks failed
Build and Deploy Container / build_and_deploy (push) Failing after 19s
Some checks failed
Build and Deploy Container / build_and_deploy (push) Failing after 19s
This commit is contained in:
@@ -19,6 +19,24 @@ jobs:
|
||||
build_and_deploy:
|
||||
runs-on: ubuntu-latest
|
||||
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
|
||||
shell: bash
|
||||
run: |
|
||||
@@ -30,7 +48,6 @@ jobs:
|
||||
# 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 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
|
||||
uses: actions/checkout@v4
|
||||
|
||||
Reference in New Issue
Block a user