TruthGate turns a static build directory into an IPFS-hosted site that can be reached by CID, optionally updated through IPNS/TGP, and served through one or more HTTPS domains.
TruthGate is designed for files that can be served without an application server:
- HTML, CSS, and JavaScript
- images, fonts, and downloadable assets
- WebAssembly
- Blazor WebAssembly output
- React, Vue, Svelte, and other SPA production builds
- static documentation sites
- pre-rendered application output
A server-rendered application that requires its own backend process is not a static site merely because it has a frontend.
A publication connects four layers:
- Site files — the current static build.
- Site CID — the immutable IPFS root produced from those files.
- Mutable identity — optional IPNS and TGP metadata pointing to the current CID.
- Domain mapping — optional HTTP routing and certificate configuration.
The CID remains independently usable even when a domain or IPNS identity is added.
- Build the site for production.
- Confirm that the build output uses relative or deployment-compatible paths.
- Open the Domains area in TruthGate.
- Create or select the domain configuration.
- Upload or publish the build output.
- Wait for the publication job to finish.
- Record the resulting CID.
- Verify the CID directly.
- If configured, verify IPNS/TGP.
- Verify the HTTPS domain.
A mapped domain is not the management portal. Requests for that host are routed to the site's published IPFS content.
An IP address or unmapped management host serves the authenticated TruthGate application.
Read Request routing before adding unusual redirects, wildcard mappings, or multiple project hosts.
TruthGate uses a self-signed fallback certificate for IP addresses and unknown hosts. Configured domains can receive ACME certificates.
For issuance to succeed:
- DNS must point to the server.
- Public TCP port
80must reach TruthGate for HTTP-01 challenges. - Public TCP port
443must reach TruthGate for HTTPS. - Another reverse proxy must not consume the challenge unless it forwards it correctly.
Use ACME staging while testing repeated certificate changes.
A single-page application often expects unknown paths to return index.html. TruthGate's mapped-domain pipeline supports SPA-oriented fallback behavior.
That fallback should not hide genuinely missing assets. Verify deep links and direct asset URLs separately.
Always verify the immutable output before debugging a domain:
https://YOUR_TRUTHGATE_HOST/ipfs/<CID>/
An authenticated gateway request may require a login session or API key depending on the route and current configuration.
From another IPFS node, a stronger validation is:
ipfs cat /ipfs/<CID>/index.htmlThis distinguishes publication problems from DNS, TLS, or domain-routing problems.
IPNS gives a stable identity whose target can change. TruthGate can also watch an IPNS name and keep its current target pinned locally.
Publishing to IPNS and subscribing to IPNS are related but distinct operations:
- Publishing updates an identity you control.
- Watching resolves an identity and maintains its targets locally.
See Pinning, IPNS, and publishing.
A TGP publication points an IPNS identity at a tiny directory containing tgp.json, optional browser fallback content, and an optional legal notice. The current field identifies the active site CID.
Read the complete TGP publisher workflow. Do not interpret TGP as a mechanism for deleting copies held by other nodes.
A published domain can expose its current CID and IPNS/TGP state through read-only metadata endpoints. These are useful for:
- deployment verification;
- freshness checks;
- monitoring;
- client-side discovery;
- cross-node pinning automation.
See Domain metadata API.
Do not assume that compiler-generated .br or .gz files should always be removed. Compression behavior depends on the current publishing and serving implementation and on how the application references those files.
Before documenting a framework-specific rule, test the exact production output through both the mapped HTTPS domain and an IPFS path. The repository documentation intentionally avoids the old universal claim that all precompressed output is unusable on IPFS.
- The build output is static.
-
index.htmlexists at the intended root. - Direct CID access works.
- Deep SPA routes work.
- Required assets return successful responses.
- Domain DNS reaches the correct host.
- Certificate issuance succeeds.
- IPNS resolves to the expected value, when used.
-
tgp.jsonvalidates, when used. - Public metadata reports the intended CID.
