lando / cli

The cli part of Lando
https://docs.lando.dev/cli
GNU General Public License v3.0
30 stars 34 forks source link

Support Orbstack on MacOS #285

Open maxfenton opened 1 week ago

maxfenton commented 1 week ago

Expected

lando would start and run with OrbStack as the running docker provider on MacOS, with its docker symlinked at /usr/local/bin/docker

Issues


  lando ERROR Error: connect ENOENT /var/run/docker.sock
    at PipeConnectWrap.afterConnect [as oncomplete] (node:net:1555:16)
From previous event:
    at Landerode.listContainers (/snapshot/cli/node_modules/@lando/core/node_modules/dockerode/lib/docker.js)
    at Landerode.list (/snapshot/cli/node_modules/@lando/core/lib/docker.js)
    at /snapshot/cli/node_modules/@lando/core/lib/engine.js
    at /snapshot/cli/node_modules/@lando/core/lib/router.js
From previous event:
    at Object.eventWrapper (/snapshot/cli/node_modules/@lando/core/lib/router.js)
    at Engine.engineCmd (/snapshot/cli/node_modules/@lando/core/lib/engine.js)
    at Engine.list (/snapshot/cli/node_modules/@lando/core/lib/engine.js)
    at /snapshot/cli/node_modules/@lando/core/hooks/app-find-localhosts.js
    at AsyncEvents.<anonymous> (/snapshot/cli/node_modules/@lando/core/app.js)
    at AsyncEvents.handle (/snapshot/cli/node_modules/@lando/core/lib/events.js)
    at /snapshot/cli/node_modules/@lando/core/lib/events.js
    at process.processImmediate (node:internal/timers:476:21)
From previous event:
    at AsyncEvents.emit (/snapshot/cli/node_modules/@lando/core/lib/events.js)
    at /snapshot/cli/node_modules/@lando/core/lib/app.js
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
    at async Object.run (/snapshot/cli/node_modules/@lando/core/tasks/restart.js)  +6ms
  lando reporting error action to report=true, url=https://metrics.lando.dev, report=true, url=https://metrics.lando.dev +9ms
  lando reported data command=lando restart, context=local, devMode=false, instance=37ac58bbfe1d2edfdbd132cdd8e8d7d19993b33a, nodeVersion=v18.19.1, mode=cli, type=Darwin, platform=darwin, release=23.6.0, arch=arm64, isWsl=false, product=lando, version=3.21.2, message=connect ENOENT /var/run/docker.sock, stack=Error: connect ENOENT /var/run/docker.sock
    at PipeConnectWrap.afterConnect [as oncomplete] (node:net:1555:16)
From previous event:
    at Landerode.listContainers (docker.js)
    at Landerode.list (docker.js)
    at /snapshot/cli/node_modules/@lando/core/lib/engine.js
    at /snapshot/cli/node_modules/@lando/core/lib/router.js
From previous event:
    at Object.eventWrapper (router.js)
    at Engine.engineCmd (engine.js)
    at Engine.list (engine.js)
    at /snapshot/cli/node_modules/@lando/core/hooks/app-find-localhosts.js
    at AsyncEvents.<anonymous> (app.js)
    at AsyncEvents.handle (events.js)
    at /snapshot/cli/node_modules/@lando/core/lib/events.js
    at process.processImmediate (timers:476:21)
From previous event:
    at AsyncEvents.emit (events.js)
    at /snapshot/cli/node_modules/@lando/core/lib/app.js
    at process.processTicksAndRejections (task_queues:95:5)
    at async Object.run (restart.js), action=error, created=2024-09-04T17:54:28.132Z +0ms```
reynoldsalec commented 1 week ago

I believe this is more or less a duplicate of https://github.com/lando/core/issues/138, you ok continuing the convo over there @maxfenton?

maxfenton commented 1 week ago

Absolutely!

maxfenton commented 1 week ago

Ok, but actually... having bypassed the problem there, this is an additional issue with lando start -- but maybe core is the right repo and not cli

reynoldsalec commented 1 week ago

Yeah lando/core is probably more appropriate @maxfenton.

Separately, have you tried symlinking the Orbstack docker.sock location? Something like ln -s ~/.orbstack/run/docker.sock ~/.docker/run/docker.sock, then restarting the Orbstack docker daemon.

maxfenton commented 1 week ago

@reynoldsalec I hadn't, but I tried it and it got me one step further but it looks like the source of lando pull is explicitly hardcoded to files in Docker Desktop for Mac. :(

reynoldsalec commented 1 week ago

lando pull on one of the recipes? Would be cool if it bootstrapped a vanilla app ok.

Regardless, I'm guessing there won't be any official support for Orbstack until after Lando v4 is released, that's sucking up most of the dev effort at this point.