-
Notifications
You must be signed in to change notification settings - Fork 10
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
Questions about the 'deploy configurations' #498
Comments
Probably it have no access to the file(does te webuser can access docker socket file?), as file_exists function fails. public function buildDockerUrl(DaemonConfig $daemonConfig): string {
if (file_exists($daemonConfig->getHost())) {
return 'http://localhost';
}
return $daemonConfig->getProtocol() . '://' . $daemonConfig->getHost();
}
Security considerations; DockerSocketProxy restricts what commands can be send to the Docker and with what arguments.
We always recomend from our side to use Docker-Socket-Proxy& |
Thanks for the clarification! Regarding "Direct communications with Docker via Suggestion 1: Wouldn't it be better to generate an error message here and not switching to local HTTP communication? Using the Docker Socket Proxy seems to be the preferred way here (for security reasons). **Suggestion 2: Maybe the should be more clear in the documentation, e.g. "always use Docker Socket Proxy, use direct communication only as last resort"? And another question: When using the Docker Socket Proxy, the documentation says the "mount" the socket in the container:
Does the webserver user also needs access to the socket in this scenario? I guess not, because its also working with no modified access rights. |
I'm referring here to the docs 'Deploy configurations': https://nextcloud.github.io/app_api/DeployConfigurations.html
Questions in bold.
When I got it right, the first (and easiest) configuration is 'NC and Docker on the same host' (see here):
/var/docker/docker.sock
I've configured this exactly as mentioned in the docs:
When testing the connection, this fails and I get following error in the NC logs:
Question 1: Why it tries to connect to localhost on port 80? Shouldn't it use the Docker socket directly (without HTTP communication)?
Question 2: Am I missing something here? Is the documentation lacking an important piece of information?
Using the Docker Socket Proxy, see "Suggested way to communicate with Docker via Docker Socket Proxy container" it works then using method A or B.
Question 3: What are the advantages/disadvantages between "direct communication via
/var/run/docker.sock
" and using the Docker Socket Proxy? Is there one recommended way when NC, Docker and ext. apps should run on the same system?Thanks in advance!
The text was updated successfully, but these errors were encountered: