mirror of
https://github.com/games-on-whales/LXC2Docker.git
synced 2026-10-16 05:12:04 +00:00
[PR #14] [MERGED] Broaden Docker API surface for Portainer #15
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
games-on-whales/LXC2Docker#15
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/games-on-whales/LXC2Docker/pull/14
Author: @JBailes
Created: 4/18/2026
Status: ✅ Merged
Merged: 4/18/2026
Merged by: @JBailes
Base:
docker-lxc-daemon← Head:aimee/session/0ec78fd2-portainer📝 Commits (10+)
216c0ddBroaden Docker API surface for Portainer compatibilitydaeb2e7Round-trip full create payload and add filter support for Portainerd7c5c8cWire privileged/capabilities, refine logs, add event filters22c861bStreaming pulls, registry auth, restart watcher, image labelsc0ed74cWire ExtraHosts/Sysctls/Tmpfs, exec resize, live limits, image events3ef49f6Named volumes, healthcheck runner, FinishedAt, blkio stats6f3dd8ePopulate /system/df, wire NanoCpus, log rotation, health polish9024da2Exec env inheritance, CPU throttle stats, rotated log tail1a12cb0Anon volumes, name conflicts, stop timeout, digests, v1 blkio6a0edacRFC3339 timestamps, container size, exec User, stop signal, 304📊 Changes
15 files changed (+5664 additions, -3868 deletions)
View changed files
📝
cmd/docker-lxc-daemon/main.go(+5 -1)📝
internal/api/containers.go(+1320 -1196)📝
internal/api/events.go(+350 -23)📝
internal/api/exec.go(+93 -157)➕
internal/api/filters.go(+159 -0)📝
internal/api/images.go(+308 -476)➕
internal/api/portainer.go(+380 -0)📝
internal/api/router.go(+96 -65)➕
internal/api/stats.go(+649 -0)📝
internal/api/system.go(+645 -490)📝
internal/api/types.go(+321 -481)📝
internal/lxc/config.go(+254 -5)📝
internal/lxc/manager.go(+711 -603)📝
internal/oci/pull.go(+223 -67)📝
internal/store/store.go(+150 -304)📄 Description
Summary
/system/df,/volumes/*,/containers/{id}/stats, pause/unpause,/eventsbroker, prune endpoints,/auth,/images/{name}/history./_pingheaders and/infofields so Portainer's engine panel recognizes the daemon as healthy./eventsnow emits real lifecycle events (create/start/stop/die/restart/pause/unpause/destroy/rename) instead of blocking forever, so Portainer's live dashboard updates as containers change state./procand cgroup v1/v2; one-shot (?stream=0) and streaming modes supported./networkslist now returns the actualgowbridge plushost/noneso the Networks tab renders with real data.ContainerJSON/ContainerSummarygain fields Portainer reads (Path,Args,Driver,Platform,GraphDriver,Ports, fullNetworkSettingswithEndpointID, mounts on the list view).lxc-freeze/pct suspend;State()maps LXCFROZEN-> Dockerpaused.Why
The daemon is marketed as a drop-in
/var/run/docker.sock, but its previous surface only covered what the CLI and compose hit. Anyone pointing Portainer at the socket saw: volumes tab broken (404), live updates never arriving (events stub blocked), dashboard stats showing "—", pause button 404ing. This PR unblocks Portainer without changing the daemon's container model.Test plan
make buildpasses on liblxc-dev hostsgo vet ./...cleandocker stats <name> --no-streamreturns populated CPU/memory/network numbersdocker eventsprints real lines on container lifecycle actions🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.