fix(cli): respect rootless Docker in compose socket and SSH host - #497
Open
santhiprakash wants to merge 1 commit into
Open
fix(cli): respect rootless Docker in compose socket and SSH host#497santhiprakash wants to merge 1 commit into
santhiprakash wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
openship up --composehardcoded the rootful Docker socket path and thehost.docker.internalSSH host, which breaks rootless Docker installs:/var/run/docker.sock:/var/run/docker.sockis not the right socket for rootless Docker.extra_hosts: ["host.docker.internal:host-gateway"]andOPENSHIP_HOST_SSH_HOST=host.docker.internalcannot be overridden, so the container cannot reachsshdunder rootless networking.Closes #482.
Changes
OPENSHIP_DOCKER_SOCKET,DOCKER_HOST, the active docker context, or rootless fallbacks ($XDG_RUNTIME_DIR/docker.sock,/run/user/<uid>/docker.sock), defaulting to/var/run/docker.sock./var/run/docker.sockinside the API container so the API's default still works.OPENSHIP_HOST_SSH_HOSToverridable and preserved acrossopenship upre-runs, defaulting tohost.docker.internal.extra_hostsand the socket mount follow the resolved.envvalues.XDG_RUNTIME_DIR, explicit.envoverrides, andOPENSHIP_HOST_SSH_HOSTpreservation.Verification
bun run --cwd apps/cli lintpasses.bun run --cwd apps/cli testpasses (233 tests).