Uninstall Dockmesh
The uninstaller mirrors the install flow: interactive by default, non-interactive with --yes. You choose per-component what to remove — stopping the service, removing the binary, removing the data directory, and so on are each separate questions you can answer independently.
What it never touches
Section titled “What it never touches”- Running containers. Stacks deployed through dockmesh keep running after uninstall. The compose project labels stay on the containers; you manage them manually with
docker composefrom their stack directories going forward. - Docker itself. dockmesh is removed, the daemon stays.
- Anything outside the dockmesh data / asset / binary / service directories.
Quick uninstall (one-liner, interactive)
Section titled “Quick uninstall (one-liner, interactive)”curl -fsSL https://get.dockmesh.dev/uninstall | sudo bashYou’ll be asked, per component:
- Stop the running service? (default Y)
- Remove the service unit / LaunchDaemon plist? (default Y)
- Remove the dockmesh binary? (default Y)
- Remove the agent installer + bundled agent binaries? (default Y)
- Remove the data directory — DB, stacks, age keys, env? (default N — destructive)
- Remove the
dockmeshservice user (Linux only)? (default Y)
The only default that’s “no” is the data directory removal. A wiped data dir can’t be recovered: the age key that encrypts your .env files and backups lives inside it, so without the key even your existing backups become undecryptable. Answer y only if you really want dockmesh gone completely.
Non-interactive
Section titled “Non-interactive”# Accept every default — keeps the data dircurl -fsSL https://get.dockmesh.dev/uninstall | sudo bash -s -- --yes
# Complete purge — data dir included. Cannot be undone.curl -fsSL https://get.dockmesh.dev/uninstall | sudo bash -s -- --purge
# See what would happen without executingcurl -fsSL https://get.dockmesh.dev/uninstall | sudo bash -s -- --dry-runManual uninstall
Section titled “Manual uninstall”If you’d rather not pipe-to-bash, the script lives at scripts/uninstall.sh in the repo. Download, inspect, run.
Or do it yourself step by step:
# Stop + disable the servicesudo systemctl disable --now dockmesh.service
# Remove the unitsudo rm /etc/systemd/system/dockmesh.servicesudo systemctl daemon-reload
# Remove the binary + CLIsudo rm /usr/local/bin/dockmesh /usr/local/bin/dmctl
# Remove agent assetssudo rm -rf /usr/local/share/dockmesh
# (Optional) remove the data directory — THIS IS DESTRUCTIVEsudo rm -rf /var/lib/dockmesh
# (Optional) remove the service usersudo userdel dockmesh# Unload the LaunchDaemonsudo launchctl bootout system/dev.dockmesh.service
# Remove the plistsudo rm /Library/LaunchDaemons/dev.dockmesh.service.plist
# Remove the binary + CLIsudo rm /usr/local/bin/dockmesh /usr/local/bin/dmctl
# Remove agent assetssudo rm -rf /usr/local/share/dockmesh
# (Optional) remove the data directory — THIS IS DESTRUCTIVEsudo rm -rf /usr/local/var/dockmeshReinstall later
Section titled “Reinstall later”If you kept the data dir, reinstalling picks up exactly where you left off — same DB, same stacks on disk, same admin user, same age key:
curl -fsSL https://get.dockmesh.dev | sudo bashsudo dockmesh initThe init wizard detects the existing data dir, skips DB initialization, and reuses your admin user. Encrypted .env files stay readable because the age key is still in place.
Troubleshooting
Section titled “Troubleshooting”“userdel dockmesh failed” — some process still runs under the dockmesh user. Usually a lingering dockmesh serve someone started manually. Kill it (sudo pkill -u dockmesh), re-run uninstall, or remove the user manually afterwards.
Data directory wasn’t removed even with --purge — as a safety check the uninstaller verifies the directory actually looks like a dockmesh data dir (contains data/, stacks/, or dockmesh.env) before deleting it. If your data dir is in a non-standard path, point the uninstaller at the right place with DOCKMESH_DATA_DIR=/your/path before running.
“uninstaller removed my binary but service didn’t stop” — you probably answered “no” to the “stop service” question. The service is still trying to start via launchd / systemd but the binary is gone. Re-run the uninstaller with --yes or remove the service unit manually.