@filipaltdelete/dockeru
v1.3.1
Published
Minimal desktop app and CLI to manage Docker containers, images, and git-repo builds
Readme
dockeru
A minimal desktop app and CLI for managing Docker on this machine: containers, images, and git repositories you build into images.
Run
npm install
npm run app # desktop app
./cli.js # CLI (also symlinked as `dockeru` into ~/.local/bin)Requires access to /var/run/docker.sock and the docker CLI (used for git builds).
Repo folder
dockeru scans one folder — the repo folder — for compose projects
(docker-compose.yml/compose.yml, one or two levels deep; projects two
levels deep are bundled under their parent "master" folder in the container
list).
By default the Containers tab only shows containers belonging to compose projects inside the repo folder — untick only repo folder in the toolbar to see everything on the machine (including non-compose containers).
Set it from the app: click ⚙ in the top-right corner, enter the path, and
save — it takes effect immediately and is stored in data/settings.json.
Leaving the field empty reverts to the default. The setting applies to the
CLI too (dockeru root <path> sets the same value).
Resolution order:
- Folder set in the app (
data/settings.json) REPO_ROOTenvironment variable- Default: the parent of the folder dockeru is cloned into
Desktop app
npm run app opens the UI as an Electron window (the backend runs embedded on
a random localhost port). A launcher is installed at
~/.local/share/applications/dockeru.desktop, so "dockeru" also appears in
the system application menu.
The launcher passes --no-sandbox only when Electron's chrome-sandbox helper
lacks its setuid permissions; to run fully sandboxed:
sudo chown root:root node_modules/electron/dist/chrome-sandbox
sudo chmod 4755 node_modules/electron/dist/chrome-sandboxCLI
The same functionality is available in the terminal via dockeru
(symlinked into ~/.local/bin, or run ./cli.js). Run dockeru help for all
commands; highlights:
dockeru ps # grouped container list, only the repo folder's projects (-a: everything)
dockeru start repo # start a master folder, project, or single container
dockeru up repo # docker compose up -d in the project dir
dockeru rebuild # docker compose up -d --build for the folder you're standing in ('b' in the UI)
dockeru logs <name> -f # follow logs
dockeru shell <name> # shell inside the container (also 't' in the full-screen UI)
dockeru root ~/projects # set the repo folder (same setting as the desktop UI ⚙)
dockeru editor code # editor used by the UI file explorer ('e'); default $EDITOR/vi
dockeru repos add app https://github.com/user/app.git && dockeru build appReordering
The order of the container groups (in dockeru ps, dockeru ui, and the
desktop UI) and of the connected repositories is customizable. In the desktop
UI, drag the ⠿ handle; from the CLI:
# Container groups (masters and standalone projects), as shown by `dockeru ps`
dockeru move webshop top # pin the webshop project first
dockeru move backoffice up # swap backoffice with the group above it
dockeru move legacy bottom # move the legacy master folder last
dockeru move api 3 # put api at position 3 (1 = first)
# Connected repositories, as shown by `dockeru repos`
dockeru repos move app top # list the app repo first
dockeru repos move tools down # swap tools with the repo below itBoth commands accept up, down, top, bottom, or a 1-based position
(out-of-range positions clamp to the ends) and print the resulting order.
The order is shared with the desktop UI — groups in data/settings.json,
repos in data/repos.json. Groups you haven't ordered sort alphabetically
after the ordered ones; the unnamed "Other containers" group always stays
last.
Features
- Containers — list running and stopped containers, start / stop / restart /
remove, view the last 300 log lines. The list auto-refreshes every 5 s.
Drag the
⠿handle to reorder the groups (shared with the CLI, see Reordering). - Images — list local images, pull from Docker Hub or any registry
(e.g.
nginx:alpine,ghcr.io/org/app:tag) with live progress, remove, and run a container from an image (with optional name, port mappingshost:container, andKEY=valenvironment variables). - Repositories — connect a git repository by URL. Build runs
docker build <git-url>(the Docker daemon clones the repo itself, so the repo needs a Dockerfile) and tags the result<name>:latest, streaming the build output live. After a build you can launch containers from it. Private repos work with URLs that embed credentials or over ssh if the daemon host has keys set up. Connected repos are stored indata/repos.jsonand can be reordered by dragging the⠿handle.
Notes
- The embedded backend has no authentication — it exposes full Docker control. It only ever binds to 127.0.0.1 on a random port for the Electron window; never make it listen on a network interface.
