From 35308eb1724f86e956d71c05098a4fe46f6a4e74 Mon Sep 17 00:00:00 2001 From: Christian Date: Fri, 2 Jan 2026 14:41:20 +0100 Subject: [PATCH] Update script syncer nu migrations fra container til host --- updateto.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/updateto.sh b/updateto.sh index c9a78d8..09c07ad 100644 --- a/updateto.sh +++ b/updateto.sh @@ -62,6 +62,18 @@ echo "" echo "🔨 Bygger nyt image med version $VERSION..." podman-compose -f docker-compose.prod.yml up -d --build +# Sync migrations from container to host +echo "" +echo "📁 Syncer migrations fra container til host..." +if podman cp bmc-hub-api-prod:/app/migrations ./migrations_temp 2>/dev/null; then + rm -rf ./migrations + mv ./migrations_temp ./migrations + chmod -R 755 ./migrations + echo "✅ Migrations synced" +else + echo "⚠️ Warning: Could not sync migrations (container might not be ready yet)" +fi + # Wait a bit for startup echo "" echo "⏳ Venter på container startup..."