Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions Formula/g/grafana-alloy.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
class GrafanaAlloy < Formula
desc "OpenTelemetry Collector distribution with programmable pipelines"
homepage "https://grafana.com/oss/alloy-opentelemetry-collector/"
url "https://github.com/grafana/alloy/archive/refs/tags/v1.12.2.tar.gz"
sha256 "9e686f6d61b899b900f90ff796827cccde49b28cceb10cda9c4c0b1775613be7"
url "https://github.com/grafana/alloy/archive/refs/tags/v1.13.0.tar.gz"
sha256 "eae757e2bf67ba6ba45a0ca00e0c58d20fdddd8a17884201d6f3f87bb5686b1b"
license "Apache-2.0"
head "https://github.com/grafana/alloy.git", branch: "main"

Expand All @@ -17,7 +17,6 @@ class GrafanaAlloy < Formula

depends_on "go" => :build
depends_on "node" => :build
depends_on "yarn" => :build

on_linux do
depends_on "systemd" # for go-systemd (dlopen-ed)
Expand All @@ -42,15 +41,15 @@ def install
]

# https://github.com/grafana/alloy/blob/main/tools/make/packaging.mk
tags = %w[netgo builtinassets]
tags = %w[netgo embedalloyui]
tags << "promtail_journal_enabled" if OS.linux?

# Build the UI, which is baked into the final binary when the builtinassets
# tag is set.
system "yarn", "--cwd", "internal/web/ui"
system "yarn", "--cwd", "internal/web/ui", "run", "build"
cd "internal/web/ui" do
system "npm", "install", *std_npm_args(prefix: false)
system "npm", "run", "build"
end

system "go", "build", *std_go_args(ldflags:, tags:, output: bin/"alloy")
system "go", "build", "-C", "collector", *std_go_args(ldflags:, tags:, output: bin/"alloy")

generate_completions_from_executable(bin/"alloy", "completion")
pkgetc.mkpath
Expand Down
Loading