Repository navigation
Closed
Labels
area: configConfiguration management and validationeffort: mediumMedium effort - 1-2 dayspriority: mediumImportant but not urgenttype: enhancementNew feature or improvement to existing functionality
Description
Summary
Create a Docker Compose file for local distributed development and Kubernetes manifests for production cluster deployment. The deploy/ directory currently exists but is completely empty.
Files to Create
deploy/docker/docker-compose.yaml
3-node ObjectFS cluster + LocalStack S3, suitable for local distributed mode development:
services:
localstack:
image: localstack/localstack:3
ports: ["4566:4566"]
environment:
SERVICES: s3
AWS_DEFAULT_REGION: us-east-1
objectfs-1:
build: ../..
command: mount --foreground --config /etc/objectfs/config.yaml s3://test-bucket /mnt/data
devices: ["/dev/fuse:/dev/fuse"]
cap_add: [SYS_ADMIN]
environment:
OBJECTFS_CLUSTER_ENABLED: "true"
OBJECTFS_CLUSTER_NODE_ID: "node-1"
OBJECTFS_CLUSTER_ADVERTISE_ADDR: "objectfs-1:7946"
OBJECTFS_CLUSTER_SEEDS: "objectfs-1:7946,objectfs-2:7946,objectfs-3:7946"
depends_on: [localstack]
objectfs-2: # mirrors objectfs-1 with node-2 identity
...
objectfs-3: # mirrors objectfs-1 with node-3 identity
...deploy/kubernetes/daemonset.yaml
Runs ObjectFS on every cluster node using /dev/fuse device (not privileged):
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: objectfs
spec:
template:
spec:
containers:
- name: objectfs
image: ghcr.io/scttfrdmn/objectfs:latest
securityContext:
capabilities:
add: ["SYS_ADMIN"]
allowPrivilegeEscalation: false
volumeMounts:
- name: fuse
mountPath: /dev/fuse
- name: mount-point
mountPath: /mnt/objectfs
mountPropagation: Bidirectional
volumes:
- name: fuse
hostPath:
path: /dev/fuse
- name: mount-point
hostPath:
path: /mnt/objectfsdeploy/kubernetes/rbac.yaml
Minimal RBAC — no cluster-admin required.
deploy/README.md
Documents both deployment modes with quick-start instructions.
Acceptance Criteria
-
docker compose up --waitstarts all 3 ObjectFS nodes and LocalStack; all nodes show as alive -
docker compose downtears down cleanly (mounts unmounted) - Kubernetes manifests pass
kubectl --dry-run=client apply -f deploy/kubernetes/ -
deploy/README.mdexplains both modes and includes a troubleshooting section
Metadata
Metadata
Assignees
Labels
area: configConfiguration management and validationeffort: mediumMedium effort - 1-2 dayspriority: mediumImportant but not urgenttype: enhancementNew feature or improvement to existing functionality
Activity
scttfrdmn commentedon Jul 30, 2026
Note from the v0.10.0 review — two corrections
deploy/does not exist. The issue states it "currently exists but is completely empty."There is no such directory in the repo, so the work is creating it rather than populating it.
Minor, but it changes the first step.
The 3-node acceptance criterion depends on #139. "All nodes show as alive" requires a working
ClusterManagerin the running process and gossip actually exchanging state. Neither is wiredtoday —
Adapterhas no cluster field, andconfig.ClusterConfigcannot be passed todistributed.NewClusterManagerwithout a translation layer (see the note on #139). It alsorequires env-var config binding for per-node identity, which should be confirmed as working or
added to scope.
Suggest either adding #139 as an explicit dependency, or splitting this into the
single-node container work (which is unblocked and useful now) and the multi-node compose
topology (which is not).
scttfrdmn commentedon Aug 2, 2026
Corrections:
deploy/does not exist, and the Compose file specifies LocalStackRe-verified against
main.1. "The
deploy/directory currently exists but is completely empty" is wrong — it does not exist at all (ls -d deploy→No such file or directory). Minor, but it changes the first step from "populate" to "create", and an empty directory would not have survived in git anyway.2. The Compose file uses LocalStack, which this project does not test against.
CLAUDE.mdstates integration tests hit real AWS S3 and explicitly says no LocalStack; v0.10.1 builtinternal/testaws/, which runs the real S3 backend against an in-process substrate endpoint over real HTTP — no network, no credentials, no account. Shipping a LocalStack dependency indeploy/would make the recommended local development path diverge from the one CI exercises, and would be a third S3 emulation story alongside substrate and real AWS.For a Compose file the choice is narrower than for tests, since substrate is in-process and Compose needs a network service. Reasonable resolutions, in order:
3. The
command:line assumes a subcommand that does not exist yet.mount --foreground --config ... s3://bucket /mnt/datarequires #134 (subcommand routing). Todaycmd/objectfs/main.gotakes exactly two positional arguments and no subcommands. The dependency should be explicit — as written the manifests would ship broken.4. The env-var names do not exist.
OBJECTFS_CLUSTER_ENABLED,OBJECTFS_CLUSTER_NODE_ID,OBJECTFS_CLUSTER_ADVERTISE_ADDR, andOBJECTFS_CLUSTER_SEEDShave zero hits repo-wide.internal/config/config.go:720-850has an explicit env-mapping table — 24 variables, none of them cluster. So this issue also owns adding those four mappings, or the manifests configure nothing. That is the same defect class as the eighteen inert FUSE fields removed in v0.10.1: a name that looks like a knob and is read by nothing. A test asserting the four variables reachConfiguration.Clusterbelongs in the acceptance criteria.5.
area: configis the wrong label for deployment manifests;area: buildorarea: docsfits better. Low stakes, but it is why this issue is easy to miss when triaging packaging work.Accurate as written: the DaemonSet's
/dev/fuse+SYS_ADMIN+allowPrivilegeEscalation: false+mountPropagation: Bidirectionalshape is right, and notably better than theprivileged: truemost FUSE-in-Kubernetes examples reach for.fix(docs): docs-platform is a documentation site, and now only that
fix(docs): docs-platform is a documentation site, and now only that
fix(docs): docs-platform is a documentation site, and now only that
fix(docs): docs-platform is a documentation site, and now only that (#…
scttfrdmn commentedon Aug 9, 2026
Scoping note: this issue specifies LocalStack, which this project rules out.
CLAUDE.md:130("Integration tests hit real AWS S3 (no LocalStack)") andCONTRIBUTING.md:189("Do not use LocalStack, and prefer not to write a mock") are both explicit, and #240 deleted an entiretests/integration/suite for targeting it. The issue text predates that decision.The replacement is
internal/testaws— the real S3 backend against an in-process substrate endpoint over real HTTP: no network, no credentials, no AWS account. For anything an emulator cannot answer, real AWS behind-tags=integrationwithAWS_PROFILE=aws AWS_REGION=us-west-2. A hand-written mock is the last resort, because a mock sits on the far side of a seam and agrees with its caller by construction — which is how 32,680 lines of tests missed roughly 45 defects.Whoever picks this up should substitute accordingly rather than following the issue body literally.
feat(deploy): Kubernetes and Compose manifests, and the cluster env v…
feat(config): refuse a wildcard advertise_addr, and an operator guide…