Преглед изворни кода

docker-images: glm53-flash-exl3

Alexander Korolev пре 1 недеља
родитељ
комит
b828622aaa

+ 8 - 0
docker-images/glm53-flash-exl3/Dockerfile

@@ -0,0 +1,8 @@
+# syntax=docker/dockerfile:1.7
+# GLM-5.3-Flash EXL3 SM121: upstream Entrpi image + instanttensor loader.
+ARG BASE_IMAGE
+FROM ${BASE_IMAGE}
+
+RUN set -eux; \
+    pip install --no-deps --no-build-isolation instanttensor==0.1.9; \
+    python3 -c "import instanttensor; print('instanttensor ok')"

+ 32 - 0
docker-images/glm53-flash-exl3/build.sh

@@ -0,0 +1,32 @@
+#!/usr/bin/env bash
+# Build the SM121 GLM-5.3-Flash NVFP4 (lab quant) image: day-0 base +
+# NoPE-MLA mod + FujitsuPolycom lab-checkpoint patches.
+#
+# Generic driver: forwards every KEY=VAL pin in versions.env as a --build-arg
+# to the Dockerfile. TAG is set by the sm121 launcher to the recipe's
+# docker_image (manual build: TAG=glm53-flash-nvfp4-lab:local bash build.sh).
+set -euo pipefail
+cd "$(dirname "$0")"
+TAG="${TAG:-glm53-flash-exl3:local}"
+
+ARGS=()
+while IFS= read -r line; do
+    case "$line" in
+        ''|\#*) continue ;;
+    esac
+    key="${line%%=*}"; val="${line#*=}"
+    val="${val%\"}"; val="${val#\"}"   # versions.env values may be shell-quoted
+    [ -n "$key" ] && ARGS+=(--build-arg "${key}=${val}")
+done < versions.env
+
+echo "=== Building ${TAG} ==="
+# Persistent buildkit cache (per node, shared across image dirs): the
+# version-independent stages (apt, torch, CUDA base) are reused across
+# rebuilds — only the pinned source stages (vllm/b12x/…) re-download and
+# re-compile. Override the dir with SM121_BUILDKIT_CACHE if desired.
+CACHE_DIR="${SM121_BUILDKIT_CACHE:-$HOME/.cache/sm121-buildkit}"
+mkdir -p "${CACHE_DIR}"
+docker buildx build "${ARGS[@]}" --cache-from "type=local,src=${CACHE_DIR}" \
+    --cache-to "type=local,dest=${CACHE_DIR},mode=max" \
+    --progress=plain --load -t "${TAG}" -f Dockerfile . 2>&1
+echo "=== Done: ${TAG} ==="

+ 4 - 0
docker-images/glm53-flash-exl3/versions.env

@@ -0,0 +1,4 @@
+# Authoritative build inputs for the GLM-5.3-Flash EXL3 SM121 image:
+# the Entrpi community GB10 image (digest-pinned) + the instanttensor
+# loader (pip, no-deps so NCCL wheel resolution is untouched).
+BASE_IMAGE="ghcr.io/entrpi/glm-5.3-flash-exl3-2x-spark:v1-dflash2@sha256:284142c5833cbfd540ad42bb8f32cb340451db05a3b84029eaebae54579e9135"