Use flags instead of config and remove attributes
This commit is contained in:
parent
5b20dad9ad
commit
665b05eedc
23 changed files with 87 additions and 162 deletions
|
|
@ -24,9 +24,9 @@ func init() {
|
|||
Factories["ntp"] = NewNtpCollector
|
||||
}
|
||||
|
||||
// Takes a config struct and prometheus registry and returns a new Collector exposing
|
||||
// Takes a prometheus registry and returns a new Collector exposing
|
||||
// the offset between ntp and the current system time.
|
||||
func NewNtpCollector(config Config) (Collector, error) {
|
||||
func NewNtpCollector() (Collector, error) {
|
||||
if *ntpServer == "" {
|
||||
return nil, fmt.Errorf("No NTP server specifies, see --ntpServer")
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue