Skip to content

Host mounts with sshfs#1

Closed
nikola-jokic wants to merge 12 commits into
G-Research-Forks:mainfrom
nikola-jokic:nikola-jokic/sshfs-volume
Closed

Host mounts with sshfs#1
nikola-jokic wants to merge 12 commits into
G-Research-Forks:mainfrom
nikola-jokic:nikola-jokic/sshfs-volume

Conversation

@nikola-jokic
Copy link
Copy Markdown

@nikola-jokic nikola-jokic commented Oct 16, 2025

This PR introduces:

  • Abstraction named volume, which is the volume mount, mounted from the engine.
  • New API providing SSHFS mount, passing down required data for the engine to mount the sshfs, which can later be used as a volume
  • Changes to the engine allowing host mounts

Important points:

  1. Dagger is built with the sshfs and fuse packages. (Should this dependency always be included since it would require starting the engine with certain permissions that might be too permissive for someone who doesn't want to use the sshfs mount?)
  2. I also exposed the host directory mount if the engine is started with the volume mount from the host. This might not be the desired behavior, but I exposed it during testing and left it for comments.
  3. Re-use of the sshfs mount so we can avoid calling mount multiple times. I will add tests around this, but it would be very beneficial to gather feedback during the review

Before this change is fully merged, I would ideally like to add more testing, but I didn't do it on purpose so that we can introduce changes quickly. The integration test proves that the feature works, so once we align fully on the design, I will add unit tests as well.

@nikola-jokic nikola-jokic changed the title host mounts, figure out last part Host mounts with sshfs Oct 16, 2025
@nikola-jokic nikola-jokic force-pushed the nikola-jokic/sshfs-volume branch 3 times, most recently from 2f98d8e to 8f1fdf6 Compare October 31, 2025 16:12
Signed-off-by: Nikola Jokic <jokicnikola07@gmail.com>
Signed-off-by: Nikola Jokic <jokicnikola07@gmail.com>
@nikola-jokic nikola-jokic force-pushed the nikola-jokic/sshfs-volume branch from 506f7fd to 940d15d Compare November 3, 2025 12:31
nikola-jokic and others added 10 commits November 3, 2025 14:13
* toolchain configuration without chaining

Signed-off-by: kpenfound <kyle@dagger.io>

* toolchain config with chaining

Signed-off-by: kpenfound <kyle@dagger.io>

* missed in prev commit

Signed-off-by: kpenfound <kyle@dagger.io>

* generate new config schema

Signed-off-by: kpenfound <kyle@dagger.io>

---------

Signed-off-by: kpenfound <kyle@dagger.io>
We've seen in CI some SQLITE BUSY errors popping up again in the
telemetry client dbs. It's *possible* (but far from confirmed) that
other performance improvements may be resulting in us writing to those
dbs faster and thus making it easier to hit that error.

Trying out a bump of the timeout to see if it helps in the short term.

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
We were erroring out in this case unnecessarily. Can just treat a nil
lower ref as scratch and set the diff as the contents of upper.

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
Signed-off-by: Erik Sipsma <erik@sipsma.dev>
Signed-off-by: Erik Sipsma <erik@sipsma.dev>
* chore: bump internal tooling to v0.19.5

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

* fix mysteriously auto-updated docs module name change

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

---------

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
* fix dagger develop --recursive to use correct dep name

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

* add changelog

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

---------

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
* dagop: never use potentially stale client metadata

We see quite a few flakes around missing sessions in the midst of dagop.
It's always when integ tests are running in parallel and a lot that are
sharing a step will hit the same error.

I think it may be a timing thing where the client metadata stored in an
op is cached in dagql, then the unlazy happens later with timing such
that the stored client metadata is okay at first but becomes invalid
later due to the session it was from disconnecting.

Instead, I think we should just always use the client metadata of
whoever is invoking the operation.

This is much simpler as easy to think through now-a-days since we
deleted edge merging, no possible concerns with multiple clients mixing
data anymore.

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

* handle per-LLB-vertex deduplication by retrying in case of stale session

The buildkit solver still merges operations if the LLB vertex digest is
the exact same. This fixes the code such that if we end up with a stale
session, the operation will be retried rather than giving all clients
waiting on the result an error just because one client disconnected.

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

* add changelog

Signed-off-by: Erik Sipsma <erik@sipsma.dev>

---------

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
Signed-off-by: Nikola Jokic <jokicnikola07@gmail.com>
@github-actions
Copy link
Copy Markdown

This PR is stale because it has been open 14 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions
Copy link
Copy Markdown

This PR was closed because it has been stalled for 7 days with no activity.

@github-actions github-actions Bot closed this Nov 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants