Documentation
¶
Index ¶
- func CreateOrUpdateAgent(db *surrealdb.DB, agent_name string, config []byte) (err error)
- func INIT(db *surrealdb.DB, api_user, api_user_pass, agent_secret string) (err error)
- func RegisterAgent(c *gin.Context, db *surrealdb.DB)
- type Agent
- type AgentConfig
- type AgentLog
- type AgentRegister
- type AgentSecret
- type ErrorResponse
- type Result
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateOrUpdateAgent ¶
create a new agent or update agent entry with the agent name and YAML configuration.
Types ¶
type AgentConfig ¶
type AgentRegister ¶
type AgentRegister struct {
Name string `json:"name"` // agent hostname
Config string `json:"config"` // base64 encoded yaml configuration
}
---- api input types
type AgentSecret ¶
type ErrorResponse ¶
type ErrorResponse struct {
Error string `json:"error" example:"Invalid input"`
}
--- api output types ---
Click to show internal directories.
Click to hide internal directories.