probe/config/path-container.go

22 lines
578 B
Go
Raw Normal View History

2018-04-18 14:56:13 +00:00
package config
import (
"fmt"
"path"
"strings"
2018-04-26 08:39:32 +00:00
occp "git.loafle.net/overflow/commons-go/config/probe"
2018-04-18 14:56:13 +00:00
)
2018-04-26 08:39:32 +00:00
func ContainerPIDFilePath(containerType occp.ContainerType) string {
2018-04-18 14:56:13 +00:00
return path.Join(PIDDir(), fmt.Sprintf("%s.pid", strings.ToLower(containerType.String())))
}
2018-04-26 08:39:32 +00:00
func ContainerBinFilePath(containerType occp.ContainerType) string {
return path.Join(BinDir(), occp.ContainerBinFileName[containerType])
2018-04-18 14:56:13 +00:00
}
2018-04-26 08:39:32 +00:00
func ContainerLoggingConfigFilePath(containerType occp.ContainerType) string {
return path.Join(BinDir(), occp.ContainerLoggingConfigFileName[containerType])
2018-04-18 14:56:13 +00:00
}