zokradonh / kopano-docker

Unofficial Kopano Docker images for all Kopano services.
MIT License
59 stars 36 forks source link

container gateway is started from unmodified config #412

Closed engelant closed 4 years ago

engelant commented 4 years ago

It seems that the configuration for the kopano gateway is updated/configured but then not used.

kopano-gateway --help
Usage:

kopano-gateway [-h|--host <serverpath>] [-c|--config <configfile>]
  -h path       Use alternate connect path (e.g. file:///var/run/socket).
                Default: file:///var/run/kopano/server.sock
  -V Print version info.
  -c filename   Use alternate config file (e.g. /etc/kopano-gateway.cfg)
                Default: /etc/kopano/gateway.cfg

It seems that there is no -F switch and the alternate config file should be set to -c /tmp/kopano/gateway.cfg here.

fbartels commented 4 years ago

Please see https://github.com/zokradonh/kopano-docker/pull/414#issuecomment-643813313

engelant commented 4 years ago

Sorry, my bad, didn't realize KOPANO_CONFIG_PATH took care of that. I guess I assumend the config not getting red as STARTTLS on IMAP wasn't working, allthough I set CA and KEY. While I found out, that the actual issue was I needed to enable imaps_listen=0.0.0.0:993 for STARTTLS on 143 to work, I assumed my "config fix" was part of the chain.

theoneandonly-vector commented 2 years ago

hey there, where exactly do you put the modded kopano-gateway.cfg on the host?

engelant commented 2 years ago

No modded config, just set a few env variables in the kopano_gateway.env.

KCCONF_GATEWAY_DISABLE_PLAINTEXT_AUTH=yes
KCCONF_GATEWAY_SSL_PRIVATE_KEY_FILE=/server/ssl/example.com.key
KCCONF_GATEWAY_SSL_CERTIFICATE_FILE=/server/ssl/fullchain.cer
KCCONF_GATEWAY_SERVER_HOSTNAME=example.com
KCCONF_GATEWAY_IMAP_PUBLIC_FOLDERS=no
KCCONF_GATEWAY_IMAPS_LISTEN=0.0.0.0:993