mirror of
https://github.com/pgsty/minio.git
synced 2026-07-22 05:30:24 +03:00
Send deployment id and minio version in http header (#14378)
This commit is contained in:
@@ -33,6 +33,14 @@ import (
|
||||
humanize "github.com/dustin/go-humanize"
|
||||
)
|
||||
|
||||
var (
|
||||
// GlobalMinIOVersion - is sent in the header to all http targets
|
||||
GlobalMinIOVersion string
|
||||
|
||||
// GlobalDeploymentID - is sent in the header to all http targets
|
||||
GlobalDeploymentID string
|
||||
)
|
||||
|
||||
const (
|
||||
serverShutdownPoll = 500 * time.Millisecond
|
||||
|
||||
@@ -196,3 +204,13 @@ func NewServer(addrs []string) *Server {
|
||||
httpServer.MaxHeaderBytes = DefaultMaxHeaderBytes
|
||||
return httpServer
|
||||
}
|
||||
|
||||
// SetMinIOVersion -- MinIO version from the main package is set here
|
||||
func SetMinIOVersion(minioVer string) {
|
||||
GlobalMinIOVersion = minioVer
|
||||
}
|
||||
|
||||
// SetDeploymentID -- Deployment Id from the main package is set here
|
||||
func SetDeploymentID(deploymentID string) {
|
||||
GlobalDeploymentID = deploymentID
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user