Skip to content

Commit

Permalink
Merge pull request #198776 from Homebrew/kubeone
Browse files Browse the repository at this point in the history
kubeone 1.9.0 (new formula)
  • Loading branch information
BrewTestBot authored Nov 24, 2024
2 parents 4acc8ba + 05989a3 commit dac82e0
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/autobump.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1494,6 +1494,7 @@ kubehound
kubekey
kubelogin
kubent
kubeone
kubergrunt
kubernetes-cli
[email protected]
Expand Down
48 changes: 48 additions & 0 deletions Formula/k/kubeone.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
class Kubeone < Formula
desc "Automate cluster operations on all your environments"
homepage "https://kubeone.io"
url "https://github.com/kubermatic/kubeone/archive/refs/tags/v1.9.0.tar.gz"
sha256 "56009d0982e99d624cfa82e433f63075c1e519273c304b4a73496670c1beed2f"
license "Apache-2.0"
head "https://github.com/kubermatic/kubeone.git", branch: "main"

bottle do
sha256 cellar: :any_skip_relocation, arm64_sequoia: "5bf47ae6c90784a9ec05d00889a2a5cd4239605c0b354370e017259358e500f1"
sha256 cellar: :any_skip_relocation, arm64_sonoma: "6ae8c30e1d7fc8476110911783fbd553bb0bc18ef276fcd7ac360be3c87859ad"
sha256 cellar: :any_skip_relocation, arm64_ventura: "d3252718f8c30f82539568717059abbb5509295d36856cfe88e0d26048520878"
sha256 cellar: :any_skip_relocation, sonoma: "59d426a43d57cd8d1e77a88ca27845e574c0429a111295f7adc7233771b053b6"
sha256 cellar: :any_skip_relocation, ventura: "df4aeb4046121b37aad39e31424b07d31ec4981e28a5512eece1f673b55d811c"
sha256 cellar: :any_skip_relocation, x86_64_linux: "424a20cb16843151ecd2c5afec8a5d16cb095d479fc42017dcc09cdd358e7d1b"
end

depends_on "go" => :build

def install
ldflags = %W[
-s -w
-X k8c.io/kubeone/pkg/cmd.version=#{version}
-X k8c.io/kubeone/pkg/cmd.date=#{time.iso8601}
]

system "go", "build", *std_go_args(ldflags:)

# upstream fish completion support PR, https://github.com/kubermatic/kubeone/pull/3471
generate_completions_from_executable(bin/"kubeone", "completion", shells: [:bash, :zsh])
end

test do
test_config = testpath/"kubeone.yaml"

test_config.write <<~YAML
apiVersion: kubeone.k8c.io/v1beta2
kind: KubeOneCluster
versions:
kubernetes: 1.30.1
YAML

assert_match "apiEndpoint.port must be greater than 0", shell_output("#{bin}/kubeone status 2>&1", 15)

assert_match version.to_s, shell_output("#{bin}/kubeone version")
end
end

0 comments on commit dac82e0

Please sign in to comment.