Repository navigation
Troubleshooting
The shipped compose files turn container logging off (logging: driver: none)
so no record of your onion's activity lands on the host's disk. That means
docker compose logs tor shows nothing. Start with the tools that work anyway:
hiddenforge status --container tor --keys ./tor-keys --json # ready? and if not, why
hiddenforge doctor --container tor --keys ./tor-keys --json # is the hardening intact?status reports a reason whenever it is not ready, and dropped_mappings lists
any service or port that was skipped. If you need Tor's own log, remove the
logging: block from the tor service for the duration of the debugging session,
recreate the container, and put it back afterwards.
Most common cause: it's just not finished booting. Tor has to bootstrap to
100%, build circuits, and establish introduction points before the address is
published, and fetching the network's relay descriptors can take several
minutes on a slow link. hiddenforge status --json says what it is waiting for
(for example bootstrap not at 100%). Give it five minutes before worrying.
"Healthy" means more than "running": bootstrapped, a circuit built, introduction points established and the descriptor uploaded for every service, and the Vanguards addon alive.
Tor is working; the problem is between Tor and your backend.
-
Is the backend on the internal network? It must share
tor-internalwith the tor container. If it's on a different network, Tor can't reach it. -
Do the name and port match? In
80:web:80, the middle part must be the exact service name of your backend in the compose file, and the last part must be the port it listens on. -
Did the backend just get recreated? HiddenForge re-checks the backend's
address every 30 seconds and restarts itself to follow a backend that moved
to a new IP, so this heals within about a minute. It needs the restart policy
the shipped files set (
restart: unless-stoppedfor Docker,alwaysfor Podman).
A bad service name, port or backend name is skipped, not fatal: the rest of your
services still come up. hiddenforge status --json lists every skipped entry in
dropped_mappings, with the reason:
- an invalid service name (lowercase letters, digits and hyphens only, starting with a letter or digit, at most 63 characters);
- an invalid or malformed mapping (a port out of range, or not
port:name:port); - two variables that map to the same service name (names are lowercased and
_becomes-, soMY_APPandmy-appcollide); - a backend name that does not resolve yet. This one heals by itself: once the
name resolves, HiddenForge restarts and adds the service, typically within a
minute. If it never does, check that the backend is running, that its name is
spelled the same as in the compose file, and that it is on
tor-internal.
For the others, fix the offending variable and recreate the container. ready
means every service Tor is configured with is reachable, and a dropped mapping
is not configured, so the container can be ready with one service missing:
also check that dropped_mappings in hiddenforge status --json is empty.
With none configured at all, the container is reported unhealthy.
A bad service name or port does not stop the container. If it exits, the cause is lower-level, and startup names it: a service directory that is a symlink or a file, a directory whose permissions cannot be corrected, or a Tor that refused its configuration. Enable logging as above to read the one line that explains it.
Two causes that used to stop Tor are handled at startup: a service directory you created yourself is set to the private mode Tor requires, and under rootless Podman a restart does not fail on the directory a previous start prepared.
hiddenforge status --json reports vanguards: false. Your service still works
on Tor's built-in vanguards-lite protection; it's degraded, not down.
HiddenForge restarts the addon by itself; if it keeps crashing it pauses for ten
minutes and tries again. Restarting the container retries at once.
The tor container needs outbound internet to reach the Tor network. Make sure it
is on the tor-external network (the non-internal one). Your backend must
not be on that network; only Tor. Otherwise, check for a host firewall blocking
outbound connections.
Do not add seccomp=unconfined (2.0.4's compose files set it; 2.1.0's do
not). Tor's sandbox does not need it: the runtime's default seccomp profile and
Tor's own sandbox stack correctly (measured on Docker and on rootless Podman), and running
unconfined only removes the filter from everything that isn't Tor.
Podman restarts containers at boot only if their restart policy is always (the shipped Podman file sets it) and only when two things are enabled for your user, once:
loginctl enable-linger $USER
systemctl --user enable podman-restart.servicehiddenforge doctor checks all three. Docker needs nothing extra.
Tor needs the host clock to be roughly correct, within about 30 minutes of real time. If the host clock has drifted, Tor can't validate the network consensus and won't bootstrap. Fix the host's time sync and restart.
Collect hiddenforge status --json and hiddenforge doctor --json, plus Tor's
log with logging temporarily enabled, note your Docker or Podman version, and
bring it to the project's channels.
Start here
Older releases
Going deeper
- The Security Model
- Verifying the Image
- Reproducing the Build
- The hiddenforge CLI
- Rootless Podman
- Backing Up Your Onion Address
- Upgrading Safely
- Running Multiple Services
Help