Update: Verwende repository.michaelschiemer.de:5000 für Git-Repository URLs

- Ändere Remote-URL zu repository.michaelschiemer.de:5000
- Aktualisiere alle Workflows (production-deploy, test-registry, security-scan, update-production-secrets)
- Test: Production Deployment Workflow
This commit is contained in:
2025-10-31 20:14:41 +01:00
parent 891508f47c
commit f1329433ce
4 changed files with 203 additions and 42 deletions

View File

@@ -0,0 +1,61 @@
name: Test Registry Credentials
on:
workflow_dispatch:
push:
branches: [ main ]
paths:
- 'scripts/test-registry-credentials.sh'
- '.gitea/workflows/test-registry.yml'
env:
REGISTRY_DOMAIN: registry.michaelschiemer.de
REGISTRY_HOST: 94.16.110.151
jobs:
test-credentials:
name: Test Registry Credentials
runs-on: docker-build
steps:
- name: Install git and setup environment
shell: sh
run: |
if ! command -v bash >/dev/null 2>&1 || ! command -v git >/dev/null 2>&1 || ! command -v curl >/dev/null 2>&1; then
apk add --no-cache git bash curl ca-certificates
fi
- name: Checkout code
shell: bash
run: |
REF_NAME="${{ github.ref_name }}"
REPO="${{ github.repository }}"
if [ -z "$REF_NAME" ]; then
REF_NAME="main"
fi
if [ -n "${{ secrets.CI_TOKEN }}" ]; then
git clone --depth 1 --branch "$REF_NAME" \
"https://${{ secrets.CI_TOKEN }}@repository.michaelschiemer.de:5000/${REPO}.git" \
/workspace/repo
else
git clone --depth 1 --branch "$REF_NAME" \
"https://repository.michaelschiemer.de:5000/${REPO}.git" \
/workspace/repo || \
git clone --depth 1 \
"https://repository.michaelschiemer.de:5000/${REPO}.git" \
/workspace/repo
fi
cd /workspace/repo
- name: Test Registry Credentials
shell: bash
env:
REGISTRY_USER: ${{ secrets.REGISTRY_USER }}
REGISTRY_PASSWORD: ${{ secrets.REGISTRY_PASSWORD }}
REGISTRY_DOMAIN: ${{ env.REGISTRY_DOMAIN }}
REGISTRY_HOST: ${{ env.REGISTRY_HOST }}
REGISTRY_PORT: 5000
run: |
cd /workspace/repo
./scripts/test-registry-credentials.sh