Files
authentik/internal/constants/constants.go
Jens L. 2b39748c84 root: Backport version 2025.2 (#13225)
* release: 2025.2.0-rc1

* release: 2025.2.0-rc2

* release: 2025.2.0-rc3

* release: 2025.2.0
2025-02-24 18:35:13 +01:00

33 lines
502 B
Go

package constants
import (
"fmt"
"os"
)
func BUILD(def string) string {
build := os.Getenv("GIT_BUILD_HASH")
if build == "" {
return def
}
return build
}
func FullVersion() string {
ver := VERSION
if b := BUILD(""); b != "" {
return fmt.Sprintf("%s+%s", ver, b)
}
return ver
}
func OutpostUserAgent() string {
return fmt.Sprintf("goauthentik.io/outpost/%s", FullVersion())
}
func UserAgent() string {
return fmt.Sprintf("authentik@%s", FullVersion())
}
const VERSION = "2025.2.0"