Some checks failed
Release / Build darwin-amd64 (push) Has been cancelled
Release / Build linux-amd64 (push) Has been cancelled
Release / Build darwin-arm64 (push) Has been cancelled
Release / Build linux-arm64 (push) Has been cancelled
Release / Create Release (push) Has been cancelled
- Add GitHub Actions workflow for multi-platform releases - Build for linux/darwin on amd64/arm64 - Auto-create GitHub Release with checksums - Version injection via ldflags - Add init.d script support for install command - Rewrite README with clearer documentation - Quick start guide - Two-node HA setup example - Health check configuration - Troubleshooting section - Bump version to 1.2.1 🤖 Generated with [Qoder][https://qoder.com]
28 lines
568 B
Go
28 lines
568 B
Go
package cmd
|
|
|
|
import (
|
|
"os"
|
|
|
|
"github.com/spf13/cobra"
|
|
)
|
|
|
|
// Version can be set at build time via ldflags
|
|
var Version = "1.2.1"
|
|
|
|
var rootCmd = &cobra.Command{
|
|
Use: "go-alived",
|
|
Short: "Go-Alived - VRRP High Availability Service",
|
|
Long: `go-alived is a lightweight, dependency-free VRRP implementation in Go.
|
|
It provides high availability for IP addresses with health checking support.`,
|
|
}
|
|
|
|
func Execute() {
|
|
if err := rootCmd.Execute(); err != nil {
|
|
os.Exit(1)
|
|
}
|
|
}
|
|
|
|
func init() {
|
|
rootCmd.Version = Version
|
|
rootCmd.CompletionOptions.DisableDefaultCmd = true
|
|
} |