Reputation: 466
How to correctly couple (Docker-)Compose with Podman and enable it through the IntelliJ IDEA UI?
The general question-idea is how to build a development setup on Windows for a Java web application (Spring Boot, actually JHipster) which relies on services running in containers?
Previously I used docker installed directly in WSL2 (Ubuntu), but it was always kind of a random thing, because of the networking problems, mainly - container to host connectivity. So I'm looking for a solid setup which can be easily grasped by other team members.
Our development setup is described primarily with the docker-compose.yml (V2) in connection with the Java Spring Boot project in an IntelliJ IDEA.
So, we need:
Currently I'm exploring a way with a Podman Desktop, also as a step towards kubernetization. So, I've done:
The dashboard looks like this:
IntelliJ IDEA Docker setup looks like this:
and
At this point, all "compose-only" services are starting ok from the IntelliJ UI, and the current blocker is an error about the docker.io/moby/buildkit
when I try to run services build with custom Dockerfile from the IntelliJ IDEA UI:
[+] Building 0.2s (0/1)
[+] Building 0.5s (1/1) FINISHED
=> ERROR [internal] booting buildkit 0.5s
=> => starting container buildx_buildkit_default 0.4s
------
> [internal] booting buildkit:
[+] Building 0.0s (1/1) FINISHED
=> CANCELED [internal] booting buildkit 0.0s
Error response from daemon: crun: create `/sys/fs/cgroup/docker/buildx`: Permission denied: OCI permission denied
`docker-compose` process finished with exit code 17
Upvotes: 7
Views: 3990
Reputation: 1
I looked to a solution for this and found that post and also this video (https://www.youtube.com/watch?v=e7uMH8aVuc4) that explains how to use podman with IntelliJ so I want to add the solution here too for seekers in the future.
To use docker-compose and podman with IntelliJ you need to adjust the settings for the Docker Plugin so it looks at the right executables.
Build, Execution, Deployment -> Docker -> Tools
Change the path for "Docker executable: " to
C:\Program Files\RedHat\Podman\podman.exe
and the path for the compose to:
C:\Users\USER\AppData\Local\Microsoft\WindowsApps\docker-compose.exe
Upvotes: 0