mirror of
https://github.com/kairos-io/kairos-agent.git
synced 2025-08-31 16:39:20 +00:00
Merge pull request #55 from c3os-io/feature/cluster-provider
Abstract Cluster Provisioning with Cluster Plugins
This commit is contained in:
committed by
Itxaka
parent
fe08c577ed
commit
43907c8d95
@@ -91,6 +91,26 @@ See https://docs.c3os.io/after_install/upgrades/#manual for documentation.
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
Name: "notify",
|
||||||
|
Usage: "notify <event> <config dir>...",
|
||||||
|
UsageText: "emits the given event with a generic event payload",
|
||||||
|
Description: `
|
||||||
|
Sends a generic event payload with the configuration found in the scanned directories.
|
||||||
|
`,
|
||||||
|
Aliases: []string{},
|
||||||
|
Flags: []cli.Flag{},
|
||||||
|
Action: func(c *cli.Context) error {
|
||||||
|
dirs := []string{"/oem", "/usr/local/cloud-config"}
|
||||||
|
args := c.Args()
|
||||||
|
if len(args) > 1 {
|
||||||
|
dirs = args[1:]
|
||||||
|
}
|
||||||
|
|
||||||
|
return agent.Notify(args[0], dirs)
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
{
|
{
|
||||||
Name: "start",
|
Name: "start",
|
||||||
Usage: "Starts the c3os agent",
|
Usage: "Starts the c3os agent",
|
||||||
|
@@ -4,8 +4,9 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
|
"github.com/c3os-io/c3os/sdk/bus"
|
||||||
|
|
||||||
"github.com/c3os-io/c3os/internal/provider"
|
"github.com/c3os-io/c3os/internal/provider"
|
||||||
"github.com/c3os-io/c3os/pkg/bus"
|
|
||||||
"github.com/mudler/go-pluggable"
|
"github.com/mudler/go-pluggable"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user