Comments (16)
Podman v2.0 now has a RESTful API which I believe is mostly docker compliant, not sure how lazydocker works exactly but it may help. Reference docs: http://docs.podman.io/en/latest/Reference.html
from lazydocker.
Yeah that works great. I did:
export DOCKER_HOST=unix:///run/user/1000/podman/podman.sock
./lazydocker
For this issue, I think a --podman option to set the defaults sensibly would make sense.
from lazydocker.
The fact that lazydocker talks directly to Docker Engine is great and I think there is a possiblity to easily implement talking to Docker or Podman, by creating an interface that would be implemented by 2 structs representing Docker client and Podman's one. I have to first get familiar with lazydocker's codebase though.
Podman's Go API is documented here:
https://github.com/containers/libpod/blob/master/API.md
Dunno more details about that, like which package to import and how to start, but I guess it can be done.
Also, I just learned about this project from HN. @jesseduffield I'm very glad that you started it (just like lazygit) and I think that I'll try to contribute some code and help as much as I can, cause I see a value in this project.
from lazydocker.
With podman installed I can run sudo lazydocker
and it works fine.
How can I get rid of sudo
?
What I tried:
- add user to
docker
group and reboot https://docs.docker.com/engine/install/linux-postinstall/ - run
sudo chmod 777 /var/run/docker.sock
- run
sudo chmod 777 /run/podman/podman.sock
Other tools from https://awesome-docker.netlify.app/#cli-tools have the exact same problem.
from lazydocker.
I'm not familiar with podman. Is that an alternative to docker for containerization?
from lazydocker.
Add this to your ~/.bashrc
for the ultra lazy among us.
alias lazypodman='DOCKER_HOST=unix:///run/user/1000/podman/podman.sock lazydocker'
from lazydocker.
FWIW You can enable Podman's socket (which is normally not needed for regular Podman usage) via: systemctl enable --now podman.socket
And then:
# docker run --rm -it -v /run/podman/podman.sock:/var/run/docker.sock lazyteam/lazydocker
from lazydocker.
After heaving read into it a bit more, podman would be slightly tricky to support, because there are loads of places where I'm talking to the docker client directly rather than using CLI commands. It's not too hard to swap over most of them, but e.g. the stats object I get back from the client to generate the graphs is very detailed and I don't believe you can get that same object from the command line
from lazydocker.
Good to have you back @dawidd6! If you need any pointers let me know :)
from lazydocker.
Podman is pretty much mature at this point, any chance of this happening?
from lazydocker.
Would you like to help?
from lazydocker.
I can test stuff for you, but sadly that's about it. (:
from lazydocker.
podman has a podman-docker abstraction library and podman-compose is a thing.
With lots of luck just installing these and alias docker-compose=podman-compose
would work.
Maybe someone more brave than me can try this.
from lazydocker.
It's not as simple as aliasing the docker cli.
I think symlinking the socket descriptor will be needed 🤔
containers/podman#4234
I wonder if lazydocker can be configured
from lazydocker.
from lazydocker.
FWIW, I can confirm that the DOCKER_HOST
approach works with Podman (rootless here), but the logs tab in lazydocker never updates and is even is empty for certain containers. Similar symptoms to #306 and #218.
from lazydocker.
Related Issues (20)
- Typo in Polish translation - seici > sieci HOT 1
- Executable file not found when try to execute commands HOT 3
- can't find a way to change the restart policy
- Set default external host/client HOT 1
- Cannot connect to the Docker daemon HOT 5
- gui.mouseEvents: true disables mouse, not gui.ignoreMouseEvents: true HOT 1
- Why Common Install .sh isn't working?
- [Question] Does it support multiple contexts?
- Containers not listed HOT 2
- Sorting feature in list of images and volumes
- fixed color show HOT 4
- Issues with updated version 23.0, it no longer works HOT 11
- rename a container HOT 2
- Installation fails on Fedora 38 with GO 1.20.8
- Unknown memory leak
- Update version execution error: could not determine host context "default" does not exist HOT 12
- Docker image missing 1.20-3.15 HOT 4
- Changed DOCKERFILE with existing hub image
- After running lazydocker, docker completely breaks and it starts to require root permissions HOT 2
- Cannot install on Debian 5.10.197-1 via curl .sh HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lazydocker.