feat: Update deployment scripts to use git fetch and reset for more reliable state management
All checks were successful
Deploy Development / deploy (push) Successful in 55s
Build Test / lint-backend (push) Successful in 0s
Build Test / build-frontend (push) Successful in 15s

This commit is contained in:
Lars 2026-04-05 11:39:15 +02:00
parent bd694b30a6
commit 952cb90973
4 changed files with 22 additions and 5 deletions

View File

@ -13,7 +13,8 @@ jobs:
set -e set -e
echo "=== Deploying to DEVELOPMENT ===" echo "=== Deploying to DEVELOPMENT ==="
cd /home/lars/docker/bodytrack-dev cd /home/lars/docker/bodytrack-dev
git pull origin develop git fetch origin develop
git reset --hard origin/develop
docker compose -f docker-compose.dev-env.yml build --no-cache docker compose -f docker-compose.dev-env.yml build --no-cache
docker compose -f docker-compose.dev-env.yml up -d docker compose -f docker-compose.dev-env.yml up -d
sleep 5 sleep 5

View File

@ -13,7 +13,9 @@ jobs:
set -e set -e
echo "=== Deploying to PRODUCTION ===" echo "=== Deploying to PRODUCTION ==="
cd /home/lars/docker/bodytrack cd /home/lars/docker/bodytrack
git pull origin main # Arbeitskopie = exakt origin/main (vermeidet Abbruch bei lokalem package-lock o. ä.)
git fetch origin main
git reset --hard origin/main
docker compose -f docker-compose.yml build --no-cache docker compose -f docker-compose.yml build --no-cache
docker compose -f docker-compose.yml up -d docker compose -f docker-compose.yml up -d
sleep 5 sleep 5

3
.gitignore vendored
View File

@ -64,4 +64,5 @@ tmp/
# Cursor MCP mit Secrets (Example: .cursor/mcp.json.example) # Cursor MCP mit Secrets (Example: .cursor/mcp.json.example)
.cursor/mcp.json .cursor/mcp.json
.claude/settings.local.jsonfrontend/package-lock.json .claude/settings.local.json
frontend/package-lock.json

View File

@ -508,8 +508,8 @@ export default function Analysis() {
{/* ── Analysen starten ── */} {/* ── Analysen starten ── */}
{tab==='run' && ( {tab==='run' && (
<div> <div>
{/* Fresh result shown immediately */} {/* Fallback: Ergebnis oben nur wenn keine Pipeline-Split-Ansicht (z. B. keine Prompts) */}
{newResult && ( {newResult && !(canUseAI && pipelinePrompts.length > 0) && (
<div style={{marginBottom:16}}> <div style={{marginBottom:16}}>
<div style={{fontSize:12,fontWeight:600,color:'var(--accent)',marginBottom:8}}> <div style={{fontSize:12,fontWeight:600,color:'var(--accent)',marginBottom:8}}>
Neue Analyse erstellt: Neue Analyse erstellt:
@ -565,6 +565,19 @@ export default function Analysis() {
</nav> </nav>
</div> </div>
<div className="analysis-split__main"> <div className="analysis-split__main">
{newResult && (
<div style={{ marginBottom: 20 }}>
<div style={{ fontSize: 12, fontWeight: 600, color: 'var(--accent)', marginBottom: 8 }}>
Neue Analyse erstellt:
</div>
<InsightCard
ins={{ ...newResult, created: new Date().toISOString() }}
onDelete={deleteInsight}
defaultOpen={true}
prompts={prompts}
/>
</div>
)}
{activeCategoryKey && (() => { {activeCategoryKey && (() => {
const group = pipelineGroups.find(g => g.categoryKey === activeCategoryKey) const group = pipelineGroups.find(g => g.categoryKey === activeCategoryKey)
if (!group?.prompts?.length) return null if (!group?.prompts?.length) return null