[ 
https://issues.apache.org/jira/browse/GUACAMOLE-2037?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17930336#comment-17930336
 ] 

Per von Zweigbergk commented on GUACAMOLE-2037:
-----------------------------------------------

I'm not sure I agree - Making guacd listen on :: will make it listen on both 
IPv4 and IPv6, it wouldn't impact how Tomcat can connect to guacd or not, since 
both options would be available, unless there's some mechanism I'm not aware of.

Ultimately though, if you'd rather this were a configurable option, that's 
definitely the safer way of doing it that'll be guaranteed not to break any 
existing deployments. There'll be no unknown unknowns.

Anyway, I think the most flexible way of doing this (and also the easiest to 
implement) would be to expose a "LISTEN_ADDRESS" parameter that defaults to 
0.0.0.0 if unset, that the user of the container would set to :: if desired. In 
future, changing the default could be reconsidered.

Anyway, I'll review the process for pull requests on this project, and submit a 
pull request for it implemented in this way, as soon as I'm ready. (I 
incorrectly assumed submitting the patch was the correct way of doing it since 
there was a form field for that in the Jira. My mistake.)

Thank you for getting back to me promptly.

> Make guacd Docker configurable for IPv6
> ---------------------------------------
>
>                 Key: GUACAMOLE-2037
>                 URL: https://issues.apache.org/jira/browse/GUACAMOLE-2037
>             Project: Guacamole
>          Issue Type: Improvement
>          Components: guacd-docker
>         Environment: Ubuntu 24.04 LTS with Docker version 28.0.0, build 
> f9ced58, with ipv6-only docker and host networking
>            Reporter: Per von Zweigbergk
>            Priority: Minor
>         Attachments: guacd-docker-ipv6.patch
>
>   Original Estimate: 0.5h
>  Remaining Estimate: 0.5h
>
> guacd-docker is hardcoded to launch guacd, binding to 0.0.0.0, which is not 
> configurable using an environment variable.
> This breaks in case you want to use guacd in an environment with IPv6, for 
> example in the case where you're using IPv6-only container networking.
> Fortunately, the fix should just be a matter of changing the CMD in the 
> Dockerfile to listen on :: instead of 0.0.0.0. This lets guacd respond to 
> both IPv4 and IPv6 connections.
> I have attached a patch that does this.
> As a workaround, it's possible to specify a different entrypoint when 
> launching guacd, as per this docker-compose.yml snippet, but this isn't 
> really a great way of doing things, because it ends up hardcoding an 
> implementation detail into configuration.
> {{services:
>   # guacd
>   guacd:
>     container_name: guacd_compose
>     image: docker.io/guacamole/guacd
>     command: "/opt/guacamole/sbin/guacd -b :: -L info -f"
>     networks:
>       - guacnetwork_compose
>     restart: always
>     volumes:
>     - ./drive:/drive:rw
>     - ./record:/record:rw
> }}
> As an alternative, it would also be possible to expose an environment 
> variable to explicitly enable IPv6 support, but I think just changing the 
> hardcoded default should be fine, and, while this might be a case of me 
> having limited imagination, I can not think of any way it could break.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to