-
Notifications
You must be signed in to change notification settings - Fork 159
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Improve docker context support #1724
Merged
kyujin-cho
merged 13 commits into
main
from
fix/installer-better-docker-context-support
Nov 22, 2023
Merged
fix: Improve docker context support #1724
kyujin-cho
merged 13 commits into
main
from
fix/installer-better-docker-context-support
Nov 22, 2023
Conversation
This file contains 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
achimnol
added
type:bug
Reports about that are not working
comp:common
Related to Common component
comp:installer
Related to Installer
type:refactor
Refactor codes or add tests.
labels
Nov 19, 2023
.fix.md -> 1724.fix.md
- Fix a bug to miss awaiting on the `determine_docker_sudo()` function. - For a docker socket residing inside the user's home directory, we can assume that it is accessible without sudo.
2 tasks
github-merge-queue bot
pushed a commit
that referenced
this pull request
Nov 22, 2023
…richer debug info (#1732)
achimnol
added a commit
that referenced
this pull request
Nov 22, 2023
Backported-from: main Backported-to: 23.09
achimnol
added a commit
that referenced
this pull request
Nov 22, 2023
…richer debug info (#1732) Backported-from: main Backported-to: 23.09
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
comp:common
Related to Common component
comp:installer
Related to Installer
comp:manager
Related to Manager component
size:L
100~500 LoC
type:bug
Reports about that are not working
type:refactor
Refactor codes or add tests.
urgency:3
Must be finished within a certain time frame.
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.
Also a follow-up to #1694.
Overall, this PR improves the search process of docker socket locations and make it consistent across other Backend.AI codebase and the installer.
common.docker.get_docker_connector()
with the installer and other Backend.AI codebase.get_docker_connector()
to support docker contexts (~/.docker/contexts/meta/...
) to detect the currently used docker host settings.docker context ls
output, I assumed thatmeta.json
always has.Endpoints.docker.Host
field.DOCKER_HOST
environment variabledetermine_docker_sudo()
sudo chmod 666 <docker-socket>
if the docker socket file resides inside the user's home directory (e.g., OrbStack, Docker Desktop) instead of the system-global/run
or/var/run
.Example on macOS with OrbStack
Example on Linux with native Docker installation
Checklist: (if applicable)