gotify / gotify/server

GOTIFY_SERVER_SSL_LETSENCRYPT_HOSTS: environment variable not working

Open
#836 41 comments 0 reactions 0 assignees View on GitHub
question
Dominant language
Go
Stars
15.9k
Forks
873
Avg merge
2d 22h
Merged PRs (30d)
6

Description

**Have you read the documentation?**
- [ × ] Yes, but it does not include related information regarding my question.
- [ ] Yes, but the steps described in the documentation do not work on my machine.
- [ ] Yes, but I am having difficulty understanding it and want clarification.

**You are setting up gotify in**
- [ × ] Docker
- [ ] Linux native platform
- [ ] Windows native platform

**Describe your problem**
Trying to set up SSL for gotify, running in a container, set up with docker compose.
Relevant compose.yaml file:
```
services:
gotify:
image: gotify/server
container_name: gotify
restart: always
ports:
- "32768:80"
- "42768:443"
environment:
GOTIFY_DEFAULTUSER_PASS: admin
GOTIFY_SERVER_SSL_ENABLED: "true"
GOTIFY_SERVER_SSL_LETSENCRYPT_HOSTS: gotify.url.xyz
GOTIFY_SERVER_SSL_PORT: 443
GOTIFY_SERVER_SSL_LETSENCRYPT_ENABLED: "true"
GOTIFY_SERVER_SSL_LETSENCRYPT_ACCEPTTOS: "true"
GOTIFY_SERVER_SSL_LETSENCRYPT_CACHE: /app/data/certs
GOTIFY_SERVER_SSL_REDIRECTTOHTTPS: "true"
volumes:
- './gotify_data:/app/data'
```
I get this error when starting the container
```
gotify | Starting Gotify version 2.6.3@2025-04-27-09:10:38
gotify | panic: yaml: unmarshal errors:
gotify | line 1: cannot unmarshal !!str `gotify....` into []string
gotify |
gotify | goroutine 1 [running]:
gotify | github.com/gotify/server/v2/config.Get()
gotify | /src/gotify/config/config.go:71 +0x1e6
gotify | main.main()
gotify | /src/gotify/app.go:31 +0x18f
gotify exited with code 2
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.