-
Notifications
You must be signed in to change notification settings - Fork 24
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
[BUG] Unable to access docker daemon #30
Comments
Yeah, As for the debug mode, again, yes it should force quit(?) if a docker connection cannot be achieved. In the mean time, I think you should be able to use the DockerHub/ghcr image, but mount your custom socket instead of the default:
Although obviously this isn't a good long term solution. Unfortunately I am away from my computer for at least another week, so I can't test, or implement, any fixes at the moment. Rust 1.71.0 has just been released, and I usually try to follow the same six week release schedule with |
@halostatue I've just pushed a branch fix/host, which I think should solve the issue. A new cli arg is available, Secondly, when in debug mode, it should exit with code 1 if there are any errors - amazed that this hasn't come up before and that I missed this. If you are unable, or unwilling, to build from source, let me know and I can upload a binary here. |
I’ll need to come back to this in a couple of days, but I can try it from source. |
Sorry for the long delay, but the fix/host branch works when setting $ docker context ls --format '{{ . | json }}' | jq -s '.[] | select(.Current == true) | .DockerEndpoint'
"unix:///Users/austin/.orbstack/run/docker.sock" But this can be considered closed because it now works with |
@halostatue Thank you for taking the time to check that it works. I wasn't really aware of the Docker context before you submitted the issue. I should probably read the docs further to make sure I fully understand it, to make One final note, did you manage to test the Thanks again |
It does: $ oxker --host (docker context ls --format '{{ . | json }}' | jq -r -s '.[] | select(.Current == true) | .DockerEndpoint') (I use fish, so that’s why the lack of |
Perfect thanks, I'll merge the branch, and probably wait til rust 1.72.0 on August 24th before publishing a new version. Will do some testing about auto context finding that can be terminal agnostic. |
I’ve done a bit more research, and I think that there’s an opportunity for a crate here to improve Docker context support across Rust projects. I suspect that there’s explicit code that could be translated from Go in the docker command-line itself, but here’s what I have seen:
meta.json: {
"Name": "orbstack",
"Metadata": {
"Description": "OrbStack"
},
"Endpoints": {
"docker": {
"Host": "unix:///Users/austin/.orbstack/run/docker.sock",
"SkipTLSVerify": false
}
}
}
[
{
"Name": "orbstack",
"Metadata": {
"Description": "OrbStack"
},
"Endpoints": {
"docker": {
"Host": "unix:///Users/austin/.orbstack/run/docker.sock",
"SkipTLSVerify": false
}
},
"TLSMaterial": {},
"Storage": {
"MetadataPath": "/Users/austin/.docker/contexts/meta/2d89b732b01a00a2d1675ed3cee9fd0f965daadf90603c989dd3afd4569c6896",
"TLSPath": "/Users/austin/.docker/contexts/tls/2d89b732b01a00a2d1675ed3cee9fd0f965daadf90603c989dd3afd4569c6896"
}
}
] Ignoring the fact that I’m not good enough with Rust to build such a crate, nor do I really have an interest in maintaining such a crate (my interest in Docker and related tools is as a user, not someone who wants to build tools for Docker), but this is what I have found. |
Thank you, highly informative and helpful.
|
The issue isn’t related to contexts, but is related to automatic resolution of If I were to weigh in on that, I would suggest:
Those could also be simplified as If you decide to implement this independently of |
Describe the bug
Oxker will not start.
To Reproduce
oxker
Trying to run
oxker
with no-gui for debugging results in a permanent hang with no messages printed afterExpected behavior
A screen similar to that which is in the README screenshot. Essentially oxker should be aware of docker contexts, but must be aware of
$DOCKER_HOST
if set.Screenshots
Desktop (please complete the following information):
My socket is in
~/.orbstack/run/docker.sock
.Additional context
Setting
$DOCKER_HOST
does not help.The text was updated successfully, but these errors were encountered: