Skip to content

Commit 02cac42

Browse files
authored
fix: actually make vector work (#619)
The old version did not unpack the folder, and I missed it because I forgot the `test` directive. this is fixed now, and more elegant.
1 parent 9b7ca58 commit 02cac42

File tree

1 file changed

+29
-6
lines changed

1 file changed

+29
-6
lines changed

vector.hcl

Lines changed: 29 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,39 @@
11
description = "A high-performance observability data pipeline."
22
homepage = "https://vector.dev/"
33
binaries = ["vector"]
4-
5-
platform "darwin" "amd64" {
6-
source = "https://github.com/vectordotdev/vector/releases/download/v${version}/vector-${version}-${xarch}-apple-darwin.tar.gz"
4+
test = "vector --version"
5+
source = "https://github.com/vectordotdev/vector/releases/download/v${version}/vector-${version}-${arch_}-${platform}.tar.gz"
6+
vars = {
7+
"arch_": "${xarch}",
8+
"platform": "apple-darwin",
79
}
810

911
platform "darwin" "arm64" {
10-
source = "https://github.com/vectordotdev/vector/releases/download/v${version}/vector-${version}-${arch}-apple-darwin.tar.gz"
12+
vars = {
13+
"arch_": "${arch}",
14+
}
1115
}
1216

1317
platform "linux" {
14-
source = "https://github.com/vectordotdev/vector/releases/download/v${version}/vector-${version}-${xarch}-unknown-linux-gnu.tar.gz"
18+
vars = {
19+
"platform": "unknown-linux-gnu",
20+
}
21+
}
22+
23+
platform "darwin" {
24+
vars = {
25+
"platform": "apple-darwin",
26+
}
27+
}
28+
29+
on "unpack" {
30+
rename {
31+
from = "${root}/vector-${arch_}-${platform}/bin/vector"
32+
to = "${root}/vector"
33+
}
1534
}
1635

17-
version "0.47.0" {
36+
version "0.47.0" "0.46.1" {
1837
auto-version {
1938
github-release = "vectordotdev/vector"
2039
}
@@ -25,4 +44,8 @@ sha256sums = {
2544
"https://github.com/vectordotdev/vector/releases/download/v0.47.0/vector-0.47.0-x86_64-apple-darwin.tar.gz": "7d2fc26bad9e6e728f3a353b2c32112316b625f5b550a3e70ff8e3775b6986ec",
2645
"https://github.com/vectordotdev/vector/releases/download/v0.47.0/vector-0.47.0-arm64-apple-darwin.tar.gz": "e0cf42aa49cfc2052ef5a149af9cd7520b57f1521c8e216692eb15408922499a",
2746
"https://github.com/vectordotdev/vector/releases/download/v0.47.0/vector-0.47.0-aarch64-unknown-linux-gnu.tar.gz": "614ff0481a901ece8634e734c94c318bf63fca34d00d0605e456dbfa3b5f80b8",
47+
"https://github.com/vectordotdev/vector/releases/download/v0.46.1/vector-0.46.1-arm64-apple-darwin.tar.gz": "9a198d7a50029e7ef0d850bf2f0970a0cf54f1e8de5b9c0070bc1f56188a0ce6",
48+
"https://github.com/vectordotdev/vector/releases/download/v0.46.1/vector-0.46.1-aarch64-unknown-linux-gnu.tar.gz": "d42dd6231f3194d3b345ecebb0f7348fb67ac957f35af98450fac000a195f9c7",
49+
"https://github.com/vectordotdev/vector/releases/download/v0.46.1/vector-0.46.1-x86_64-unknown-linux-gnu.tar.gz": "a82b5a35fa76d35a3c9882fa8fe81aaae295394f20f5f4b868cfeada616e05d9",
50+
"https://github.com/vectordotdev/vector/releases/download/v0.46.1/vector-0.46.1-x86_64-apple-darwin.tar.gz": "6d8ba3fb2e0a71911549b27ee62f4ecb34a0e1314d15e1147f546e3b3a5f72be",
2851
}

0 commit comments

Comments
 (0)