Coder Social home page Coder Social logo

Comments (9)

Zomono avatar Zomono commented on June 3, 2024 1

Also discussed here, for making the podman socket path configurable:

* [Implement option to view rootful containers on Linux 🐧 #2861](https://github.com/containers/podman-desktop/issues/2861)

I think my issue is a little bit different. I only have one docker installation (rootless) while the other issue has two docker installations at the same time. And my only problem is that Docker Desktop could not find the socket file.

So making this currently hard coded path configurable either by a settings entry or by an environment variable would already solve my issue.

from podman-desktop.

Zomono avatar Zomono commented on June 3, 2024 1

But Podman Desktop then still has to "find" the correct socket path, because the path depends on the user and its id.

from podman-desktop.

benoitf avatar benoitf commented on June 3, 2024

extension could also scan for /run/user/<user-id>/docker.sock (in addition to global socket of Docker)

how did you setup your docker installation ?

also are you using docker context command ?

from podman-desktop.

Zomono avatar Zomono commented on June 3, 2024

I followed these steps to setup docker: https://docs.docker.com/engine/security/rootless/
Until now I have not used docker context.

I already tried to add /run/user/1000/docker.sock to the permission list of flatpak without luck.
If i create a symlink locally from /run/user/1000/docker.sock to /run/docker.sock, it works.

extension could also scan for /run/user//docker.sock (in addition to global socket of Docker)

I could not find any code searching for /run/user in the extension file https://github.com/containers/podman-desktop/blob/main/extensions/docker/src/extension.ts. What am I missing?

from podman-desktop.

benoitf avatar benoitf commented on June 3, 2024

https://github.com/containers/podman-desktop/blob/main/extensions/docker/src/extension.ts#L150

here, on linux we could search for other paths if file exists

from podman-desktop.

afbjorklund avatar afbjorklund commented on June 3, 2024

Also discussed here, for making the podman socket path configurable:

from podman-desktop.

afbjorklund avatar afbjorklund commented on June 3, 2024

I don't think Podman Desktop supports docker contexts or podman connections, it works directly with hardcoded unix paths.

It also doesn't yet support remote sockets like tcp or ssh, but I think supporting those are in the backlog (EDIT: #279)

from podman-desktop.

afbjorklund avatar afbjorklund commented on June 3, 2024

Choosing between "system" or "user" socket would probably be enough

It could support more (arbitrary path) for e.g. docker machine, but that is more of advanced feature and not needed for the simple Boolean scenario

from podman-desktop.

afbjorklund avatar afbjorklund commented on June 3, 2024

But Podman Desktop then still has to "find" the correct socket path, because the path depends on the user and its id.

It already knows how to do this, but it is only enabled for Podman and not for Docker (and vice-verse for the other socket)

function getLinuxSocketPath(): string {
  // grab user id of the user
  const userInfo = os.userInfo();
  const uid = userInfo.uid;

  return `/run/user/${uid}/podman/podman.sock`;
}
  const isWindows = os.platform() === 'win32';
  if (isWindows) {
    socketPath = '//./pipe/docker_engine';
  } else {
    socketPath = '/var/run/docker.sock';
  }

from podman-desktop.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.