Dev Containers with Podman

Following QA from here Workaround to use Podman in Dev Containers by Ravi, still unable to use Dev Containers with Podman.

Currently, I use VSCode with Dev Containers & Podman and it works smoothly. Purchase Cursor Pro to leverage code with AI.

Could Ravi or anyone give suggestions?

Steps to reproduce :

First step : Create podman.socket service (done)

❯ systemctl --user status podman.socket                                                                                                                                                       
● podman.socket - Podman API Socket                                                                                                                                                           
     Loaded: loaded (/usr/lib/systemd/user/podman.socket; enabled; preset: enabled)                                                                                                           
     Active: active (listening) since Fri 2025-12-26 23:49:46 WIB; 22s ago                                                                                                                    
 Invocation: a17d97266673400eba5ae1687a60fa8f                                                                                                                                                 
   Triggers: ● podman.service                                                                                                                                                                 
       Docs: man:podman-system-service(1)                                                                                                                                                     
     Listen: /run/user/1000/podman/podman.sock (Stream)                                                                                                                                       
     CGroup: /user.slice/user-1000.slice/[email protected]/app.slice/podman.socket                                                                                                            
                                                                                                                                                                                              
Dec 26 23:49:46 myWork systemd[2037]: Listening on podman.socket - Podman API Socket.

Second step : create environment variable $DOCKER_HOST (done)

❯ echo $DOCKER_HOST                                                         
unix:///run/user/1000/podman/podman.sock

Third step : create podman context

❯ podman context ls                                                                           
Name             URI                                       Identity    Default     ReadWrite
cursor-ai-usage  unix:///run/user/1000/podman/podman.sock              true        true

Run Dev Containers :

  2025-12-27 01:33:50.448 [info] No remote exec server found for authority: undefined; using local
2025-12-27 01:33:50.448 [info] Spawned process 3173424: 'podman' 'info'
2025-12-27 01:33:50.448 [info] [docker info]: Running command: podman
2025-12-27 01:33:52.981 [info] [docker info]: Command completed with exit code 0
2025-12-27 01:33:52.981 [info] docker version: host:
  arch: amd64
  buildahVersion: 1.39.3
  cgroupControllers:
  - cpu
  - memory
  - pids
  cgroupManager: systemd
  cgroupVersion: v2
  conmon:
    package: conmon_2.1.12-4_amd64
    path: /usr/bin/conmon
    version: 'conmon version 2.1.12, commit: unknown'
  cpuUtilization:
    idlePercent: 95.55
    systemPercent: 1.09
    userPercent: 3.36
  cpus: 12
  databaseBackend: sqlite
  distribution:
    codename: trixie
    distribution: debian
    version: "13"
  eventLogger: journald
  freeLocks: 2036
  hostname: myWork
  idMappings:
    gidmap:
    - container_id: 0
      host_id: 1000
      size: 1
    - container_id: 1
      host_id: 100000
      size: 65536
    uidmap:
    - container_id: 0
      host_id: 1000
      size: 1
    - container_id: 1
      host_id: 100000
      size: 65536
  kernel: 6.12.48+deb13-amd64
  linkmode: dynamic
  logDriver: journald
  memFree: 398049280
  memTotal: 16404877312
  networkBackend: netavark
  networkBackendInfo:
    backend: netavark
    dns:
      package: aardvark-dns_1.14.0-3_amd64
      path: /usr/lib/podman/aardvark-dns
      version: aardvark-dns 1.14.0
    package: netavark_1.14.0-2_amd64
    path: /usr/lib/podman/netavark
    version: netavark 1.14.0
  ociRuntime:
    name: crun
    package: crun_1.21-1_amd64
    path: /usr/bin/crun
    version: |-
      crun version 1.21
      commit: 10269840aa07fb7e6b7e1acff6198692d8ff5c88
      rundir: /run/user/1000/crun
      spec: 1.0.0
      +SYSTEMD +SELINUX +APPARMOR +CAP +SECCOMP +EBPF +CRIU +WASM:wasmedge +YAJL
  os: linux
  pasta:
    executable: /usr/bin/pasta
    package: passt_0.0~git20250503.587980c-2_amd64
    version: ""
  remoteSocket:
    exists: true
    path: /run/user/1000/podman/podman.sock
  rootlessNetworkCmd: pasta
  security:
    apparmorEnabled: false
    capabilities: CAP_CHOWN,CAP_DAC_OVERRIDE,CAP_FOWNER,CAP_FSETID,CAP_KILL,CAP_NET_BIND_SERVICE,CAP_SETFCAP,CAP_SETGID,CAP_SETPCAP,CAP_SETUID,CAP_SYS_CHROOT
    rootless: true
    seccompEnabled: true
    seccompProfilePath: /usr/share/containers/seccomp.json
    selinuxEnabled: false
  serviceIsRemote: false
  slirp4netns:
    executable: /usr/bin/slirp4netns
    package: slirp4netns_1.2.1-1.1_amd64
    version: |-
      slirp4netns version 1.2.1
      commit: 09e31e92fa3d2a1d3ca261adaeb012c8d75a8194
      libslirp: 4.8.0
      SLIRP_CONFIG_VERSION_MAX: 5
      libseccomp: 2.6.0
  swapFree: 27308032
  swapTotal: 8649699328
  uptime: 110h 47m 32.00s (Approximately 4.58 days)
  variant: ""
plugins:
  authorization: null
  log:
  - k8s-file
  - none
  - passthrough
  - journald
  network:
  - bridge
  - macvlan
  - ipvlan
  volume:
  - local
registries:
  search:
  - docker.io
  - quay.io
store:
  configFile: /home/myWork/.config/containers/storage.conf
  containerStore:
    number: 8
    paused: 0
    running: 5
    stopped: 3
  graphDriverName: overlay
  graphOptions: {}
  graphRoot: /home/myWork/.local/share/containers/storage
  graphRootAllocated: 395045117952
  graphRootUsed: 222699704320
  graphStatus:
    Backing Filesystem: extfs
    Native Overlay Diff: "true"
    Supports d_type: "true"
    Supports shifting: "false"
    Supports volatile: "true"
    Using metacopy: "false"
  imageCopyTmpDir: /var/tmp
  imageStore:
    number: 9
  runRoot: /run/user/1000/containers
  transientStore: false
  volumePath: /home/myWork/.local/share/containers/storage/volumes
version:
  APIVersion: 5.4.2
  BuildOrigin: Debian
  Built: 1753478586
  BuiltTime: Sat Jul 26 04:23:06 2025
  GitCommit: ""
  GoVersion: go1.24.4
  Os: linux
  OsArch: linux/amd64
  Version: 5.4.2
2025-12-27 01:33:52.993 [info] Spawned process 3173546: 'podman' 'container' 'ls' '--all' '--format' 'json'
2025-12-27 01:33:52.993 [info] [docker container]: Running command: podman
2025-12-27 01:33:53.044 [info] [docker container]: Command completed with exit code 0
2025-12-27 01:33:53.044 [error] Failed to list containers. Likely because Docker is not running. SyntaxError: Unexpected end of JSON input

Does this stop you from using Cursor

Yes, cursor is unusable

Hey, thanks for the report.

Unfortunately, Podman isn’t officially supported for Cursor Dev Containers. The workaround doesn’t work in all cases because the Anysphere Dev Containers extension expects a specific Docker API response format, and Podman doesn’t always match it.

The SyntaxError: Unexpected end of JSON input error suggests that podman container ls --format json is returning empty or invalid JSON for the extension.

Possible options:

  1. Recommended: Use Docker instead of Podman for Dev Containers in Cursor.
  2. Temporary workaround: Check the output of podman container ls --all --format json. If it’s empty or invalid JSON, that’s the cause.

If Docker doesn’t fit your workflow, let me know and I’ll pass the feedback to the team.

Thanks for the respons, Dean. Unfortunately, for some reasons, we have to use Podman in development env.

Hopefully Cursor Teams will support Podman in the future. In the meantime, I will use cursor cli.

1 Like

Please add support for podman

1 Like