V1.1.0 Responsive
Footer angepasst Lauffähigkeit auf Server verbessert deploy.sh mit for loop
This commit is contained in:
@@ -1,24 +1,38 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Script zum Bauen und Pushen der Docker Images zur Registry
|
||||
# Script zum Bauen und Pushen der Docker Images zur Registry (Multi-Plattform)
|
||||
set -e
|
||||
|
||||
REGISTRY="docker.citysensor.de"
|
||||
PROJECT="wetterstation"
|
||||
PLATFORMS="linux/amd64,linux/arm64"
|
||||
|
||||
echo "🔨 Building Docker images..."
|
||||
docker compose build collector
|
||||
docker compose build api
|
||||
docker compose build frontend
|
||||
echo "🔧 Setting up buildx builder..."
|
||||
# Erstelle oder verwende existierenden Builder
|
||||
docker buildx create --name multiplatform --use 2>/dev/null || docker buildx use multiplatform
|
||||
|
||||
echo ""
|
||||
echo "📤 Pushing images to ${REGISTRY}..."
|
||||
docker compose push collector
|
||||
docker compose push api
|
||||
docker compose push frontend
|
||||
echo "🔨 Building and pushing Docker images for ${PLATFORMS}..."
|
||||
|
||||
# Baue und pushe alle Images mit buildx
|
||||
docker buildx build --platform ${PLATFORMS} \
|
||||
-t ${REGISTRY}/${PROJECT}/collector:latest \
|
||||
--push \
|
||||
./collector
|
||||
|
||||
docker buildx build --platform ${PLATFORMS} \
|
||||
-t ${REGISTRY}/${PROJECT}/api:latest \
|
||||
--push \
|
||||
./api
|
||||
|
||||
docker buildx build --platform ${PLATFORMS} \
|
||||
-t ${REGISTRY}/${PROJECT}/frontend:latest \
|
||||
--push \
|
||||
./frontend
|
||||
|
||||
echo ""
|
||||
echo "✅ Done! Images successfully pushed to ${REGISTRY}"
|
||||
echo "✅ Done! Multi-platform images successfully pushed to ${REGISTRY}"
|
||||
echo " Platforms: ${PLATFORMS}"
|
||||
echo ""
|
||||
echo "To pull and run on another machine:"
|
||||
echo " docker compose pull"
|
||||
|
||||
Reference in New Issue
Block a user