16 lines
392 B
Go
16 lines
392 B
Go
package config
|
|
|
|
import (
|
|
"path"
|
|
|
|
ocscm "git.loafle.net/overflow/commons-go/sensorconfig/model"
|
|
)
|
|
|
|
func SensorConfigContainerDir(name string) string {
|
|
return path.Join(ConfigDir(), name)
|
|
}
|
|
|
|
func SensorConfigFilePath(sensorConfig *ocscm.SensorConfig) string {
|
|
return path.Join(SensorConfigContainerDir(sensorConfig.Crawler.Container), sensorConfig.Crawler.Name, sensorConfig.ID.String())
|
|
}
|