{"id":20002233,"url":"https://github.com/jzombie/sshfs-mac-docker","last_synced_at":"2025-06-13T11:33:46.435Z","repository":{"id":214931525,"uuid":"737712602","full_name":"jzombie/sshfs-mac-docker","owner":"jzombie","description":"SSHFS on macOS without macFUSE or kernel extensions.","archived":false,"fork":false,"pushed_at":"2024-01-06T21:54:48.000Z","size":16,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-11-13T05:21:31.040Z","etag":null,"topics":["docker","macos","sshfs-mounting"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jzombie.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2024-01-01T07:31:45.000Z","updated_at":"2024-08-31T19:28:01.000Z","dependencies_parsed_at":"2024-01-14T16:13:36.207Z","dependency_job_id":"cb2760e3-8617-4393-bc17-7e0ae07da610","html_url":"https://github.com/jzombie/sshfs-mac-docker","commit_stats":{"total_commits":17,"total_committers":2,"mean_commits":8.5,"dds":0.3529411764705882,"last_synced_commit":"a035c83fb03ac1d41c3a6ca920fe426a616fa708"},"previous_names":["jzombie/sshfs-mac-docker"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jzombie%2Fsshfs-mac-docker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jzombie%2Fsshfs-mac-docker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jzombie%2Fsshfs-mac-docker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jzombie%2Fsshfs-mac-docker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jzombie","download_url":"https://codeload.github.com/jzombie/sshfs-mac-docker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":233606400,"owners_count":18701616,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","macos","sshfs-mounting"],"created_at":"2024-11-13T05:20:10.500Z","updated_at":"2025-01-12T13:14:42.049Z","avatar_url":"https://github.com/jzombie.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# sshfs-mac-docker\n\n_Experimental_ repo to provide SSHFS to Mac *WITHOUT* installing macFUSE and patching the kernel with a custom kext.\n\nRemote filesystem is mounted in container via SSHFS and exposed to Mac via Samba.\n\n---\n\nNote: It is _highly_ recommended to use [OrbStack](https://orbstack.dev/).  Docker Desktop will not work for this without modifying the network routing.\n\n---\n\n## Why Samba instead of Volume Mounts?\n\nThe standard Docker volume mounts won't work for this purpose because they are designed for local file systems and do not natively support SSH-based file system connections. The sshfs-mac-docker solution uses SSHFS to overcome this limitation, allowing remote file systems to be mounted inside Docker containers as if they were local volumes, which is not achievable with Docker's standard volume mounting features.\n\n----\n\n## Build the container\n\n```bash\ndocker build -t docker-sshfs . \n```\n\n\n## Start the container\n\nIn one terminal shell, run:\n\n```bash\ndocker run --privileged --name docker-sshfs -p 127.0.0.1:139:139 -p 127.0.0.1:445:445 docker-sshfs\n```\n\nSamba is configured to listen on ports 139 and 445 and is accessible only from localhost.\n\n## Mounting Remote Filesystem\n\nIn another terminal:\n\n```bash\ndocker exec -it docker-sshfs bash\n```\n\nYou'll be dropped into the container at this point.\n\nRun (replacing `user@host:path` with your SSHFS endpoint):\n\n```bash\nsshfs -o allow_other,uid=1000,gid=1000 user@host:path /samba-share\n```\n\nallow-other is needed to be able to access via mac samba\nuid=1000,gid=1000 is needed for write-access (otherwise, it will be read-only if omitted)\n\n## Connecting to Samba share in container\n\n1. Find Docker IP of container (localhost doesn't seem to work for this)\n\n```bash\ndocker inspect --format '{{ .NetworkSettings.IPAddress }}' docker-sshfs\n```\n\n2. Navigate to Finder -\u003e Go -\u003e Connect to Server\n\n3. Enter `smb://ip-of-docker-container``\n\n    If all goes well, connect as `Guest`.\n\n4. Open `Finder`, navigate to `Network` tab, find the IP of the Docker container, and you should now have access to remote files\n\n## Unmounting Remote Filesystem\n\nIf wanting to unmount the SSHFS endpoint (without stopping the container):\n\n```bash\nfusermount -u /samba-share\n```\n\nIf getting message\n\n```bash\nfusermount: failed to unmount /samba-share: Device or resource busy\n```\n\n...unmount the drive from Finder (or just stop the container)\n\n## Not wanting Docker?\n\nMaybe this will work instead: https://github.com/macos-fuse-t/fuse-t\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjzombie%2Fsshfs-mac-docker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjzombie%2Fsshfs-mac-docker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjzombie%2Fsshfs-mac-docker/lists"}