Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

GOTIFY_SERVER_SSL_LETSENCRYPT_HOSTS: environment variable not working

Aperta
#836 41 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 2 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
go
Ambito
backend

Direzione di ricerca

Riproduci il fallimento all’avvio con l’ambiente Docker Compose fornito e ispeziona github.com/gotify/server/v2/config in config/config.go:71, dove si verifica l’errore di unmarshalling YAML. Controlla come viene letto GOTIFY_SERVER_SSL_LETSENCRYPT_HOSTS; l’attività è completata quando il container accetta l’impostazione e si avvia senza questo panic.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

question

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
Lingua principale
Go
Stelle
16k
Fork
891
Merge medio
2g 11h
PR unite (30g)
6

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di gotify/server

Tutte le issue di gotify/server

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.