Run a real cluster on one machine
Build the binaries and start 3 control-plane members and 4 hosts as separate processes, with real keys, signatures, Raft and WireGuard — all on loopback. The outputs below were recorded on the reference machine.
01Clone and build
Produces dh, dh-control, dh-noded, dh-conformance and dh-beacon in bin/.
shell$ git clone https://github.com/CodesbyFebin/Decentralized-.git decentralized.host$ cd decentralized.host$ make build02Start the cluster
Bootstraps Raft, joins 4 hosts (one edge), pushes the sample artifact and deploys a 3-replica app.
shell$ ./bin/dh dev up --dir ./devclusterrecorded outputcluster dev: root key EYpyLqc4JrBBnN9oKo9uR2PzyItlmh0W_thMZdRAI24 (dh1moxcikagjbglhwfnm3yhzxyi2i) root CA ./devcluster/operator/dev/root-ca.pem Keep ./devcluster/operator/dev/root/identity.key private: it is the trust anchor every host pins. • starting 3 control-plane member(s) bootstrapped dh1cqtai3x2ugv27ajz6x6xvg43ob: cluster dev initialized member dh1wy2x6dkhlmcdzay46pdsiu3rc4 added (roster v2, 2 members) member dh1qn4s24gwcmp7ugv4c6ietg2u53 added (roster v3, 3 members) • starting 4 host(s) (1 edge) • pushing the dh-beacon artifact and applying the sample app attestation stored for b3:87f2505fb60558d69744209dc3540a9ac54c53d87a6e68c2966ebd01981ae34f web: created (generation 1) Cluster "dev" is running: 3 control-plane member(s), 4 host(s), 1 edge. console: http://127.0.0.1:17701/#token=<session capability — redacted> operator: export DH_HOME=./devcluster/operator edge: curl -H 'Host: web.dev.test' -H 'X-DH-No-Redirect: 1' http://127.0.0.1:18103/ logs: ./devcluster/logs stop: dh dev down --dir ./devcluster
03Point the CLI at it
The operator home holds the dev cluster's root key and CA.
shell$ export DH_HOME=./devcluster/operator04Compare desired, admitted and observed
Three separate numbers. If a host refused a replica, ADMITTED would be lower than DESIRED and describe would show why.
shell$ ./bin/dh get appsrecorded outputAPP GEN IMAGE RUNTIME REPLICAS DESIRED ADMITTED OBSERVED DRIFT STATE web 1 dh-beacon@b3:87f2505fb60558d69744209dc3540a9ac54c53d87a6e68c2966ebd01981ae34f process 3 3 3 3 0 active
05Verify the audit ledger yourself
The chain and signed checkpoints are verified on your machine, not reported by the server.
shell$ ./bin/dh audit verifyrecorded outputaudit verified locally: 48 entries, head b68dc824b42b, 2 signed checkpoint(s) by roster members
06Stop everything
Stops every process and workload of the cluster.
shell$ ./bin/dh dev down --dir ./devclusterrecorded outputstopped 7 process(es) and 3 workload(s) of ./devcluster
- Dev clusters serve the API without TLS unless you pass --tls.
- Ports start at 17700 by default; change with --base if something else uses them.