Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var RegisterCmd = &cobra.Command{
Use: "register",
Short: "Register this server with Alpacon",
Long: `Register this server with Alpacon.
Requires an API token with servers:register scope.
Groups are automatically assigned from the token's allowed_groups configuration.
Examples:
sudo alpamon register --url https://alpacon.example.com --token <TOKEN>
sudo alpamon register --url https://alpacon.example.com --token <TOKEN> --name my-server
Options:
--url Alpacon server URL (required)
--token API token (servers:register scope required)
--name Server name (optional, defaults to hostname)
--platform Platform (debian/rhel, auto-detect if omitted)
--ssl-verify SSL certificate verification (default: true)
--ca-cert CA certificate path`,
RunE: runRegister,
}
RegisterCmd represents the register command
Functions ¶
This section is empty.
Types ¶
type RegisterRequest ¶
RegisterRequest represents the request body for server registration
type RegisterResponse ¶
type RegisterResponse struct {
ID string `json:"id"`
Key string `json:"key"`
Name string `json:"name"`
}
RegisterResponse represents the response from server registration
Click to show internal directories.
Click to hide internal directories.