update Dockerfile for multi-platform support and increment version to 20

master
Marius Ensrud 4 months ago
parent 313ae786c3
commit d8b4f54f68
No known key found for this signature in database

@ -1,12 +1,14 @@
FROM ghcr.io/openclaw/openclaw:latest
# syntax=docker/dockerfile:1.4
FROM --platform=linux/amd64 ghcr.io/openclaw/openclaw:latest
USER root
# Install everything in a single layer to reduce layer count
RUN apt-get update && apt-get install -y --no-install-recommends \
python3-pip \
jq \
gh \
&& rm -rf /var/lib/apt/lists/*
RUN pip install --no-cache-dir --break-system-packages \
&& rm -rf /var/lib/apt/lists/* \
&& pip install --no-cache-dir --break-system-packages \
google-auth \
google-auth-oauthlib \
google-api-python-client \

@ -1,8 +1,23 @@
#!/usr/bin/env bash -e
#!bash -e
VERSION_FILE=VERSION
current=$(cat $VERSION_FILE)
tag=$((current + 1))
docker buildx build --platform linux/amd64,linux/arm64 -t docker.bassengvegen.com/openclaw:${tag} .
docker push docker.bassengvegen.com/openclaw:${tag}
# Ensure buildx is set up properly for cross-platform builds
docker buildx create --use --name multiplatform || docker buildx use multiplatform
# Build and push with proper multi-platform support
DOCKER_BUILDKIT=1 docker buildx build \
--platform linux/amd64 \
--push \
--progress=plain \
--provenance=false \
--sbom=false \
--output type=registry,oci-mediatypes=false,compression=gzip,compression-level=9,force-compression=true \
-t docker.bassengvegen.com/openclaw:${tag} \
--no-cache \
.
echo $tag > $VERSION_FILE
echo "Successfully built and pushed openclaw:${tag}"
Loading…
Cancel
Save