Initial commit
This commit is contained in:
commit
66cf1fc9aa
30 changed files with 2735 additions and 0 deletions
20
plugin/plugin.go
Normal file
20
plugin/plugin.go
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
// Command plugin is the happyDomain plugin entrypoint for the blacklist
|
||||
// checker.
|
||||
//
|
||||
// Build with `go build -buildmode=plugin -o checker-blacklist.so ./plugin`.
|
||||
package main
|
||||
|
||||
import (
|
||||
bl "git.happydns.org/checker-blacklist/checker"
|
||||
sdk "git.happydns.org/checker-sdk-go/checker"
|
||||
)
|
||||
|
||||
var Version = "custom-build"
|
||||
|
||||
// NewCheckerPlugin is the symbol resolved by happyDomain when loading
|
||||
// the .so file. It returns the checker definition and the observation
|
||||
// provider that the host registers globally.
|
||||
func NewCheckerPlugin() (*sdk.CheckerDefinition, sdk.ObservationProvider, error) {
|
||||
bl.Version = Version
|
||||
return bl.Definition(), bl.Provider(), nil
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue