Windows server support

This commit is contained in:
binwiederhier
2026-01-17 14:43:43 -05:00
parent 9f3883eaf0
commit 6d5cc6aeac
9 changed files with 304 additions and 46 deletions

17
server/config_windows.go Normal file
View File

@@ -0,0 +1,17 @@
//go:build windows
package server
import (
"os"
"path/filepath"
)
func init() {
programData := os.Getenv("ProgramData")
if programData == "" {
programData = `C:\ProgramData`
}
DefaultConfigFile = filepath.Join(programData, "ntfy", "server.yml")
DefaultTemplateDir = filepath.Join(programData, "ntfy", "templates")
}