Files
seaweedfs/weed/storage/blockvol/operator/Dockerfile
T
Ping QiuandClaude Opus 4.6 8fa1829992 feat: Phase 9A -- Kubernetes operator MVP for SeaweedFS block storage, 71 tests
Nested Go module (operator/go.mod) isolating controller-runtime deps.
CRD SeaweedBlockCluster (block.seaweedfs.com/v1alpha1) with dual-mode:
CSI-only (MasterRef) connects to existing cluster; full-stack (Master)
deploys master+volume StatefulSets. Single reconciler manages all
sub-resources with ownership labels, finalizer cleanup, CHAP secret
auto-generation, and multi-CR conflict detection.

Review fixes: cross-NS label ownership (H1), ParseQuantity validation (H2),
volume readiness probe (M1), leader election (M2), PVC StorageClassName (M3),
condition type separation (M4), FQDN master address (L1), port validation (L3).

QA adversarial fixes: ExtraArgs override rejection (BUG-QA-1), malformed
lastRotated infinite rotation (BUG-QA-2), DNS label length validation
(BUG-QA-3), replicas=0 error message (BUG-QA-4), RFC 1123 name validation
(BUG-QA-5), whitespace field trimming (BUG-QA-6), zero storage size (BUG-QA-7).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-08 12:04:17 -07:00

13 lines
296 B
Docker

FROM golang:1.24 AS builder
WORKDIR /workspace
COPY go.mod go.sum ./
RUN go mod download
COPY . .
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o operator .
FROM gcr.io/distroless/static:nonroot
WORKDIR /
COPY --from=builder /workspace/operator .
USER 65532:65532
ENTRYPOINT ["/operator"]