mirror of
https://github.com/immich-app/yucca.git
synced 2026-09-30 13:33:00 +08:00
15 lines
594 B
Python
Executable File
15 lines
594 B
Python
Executable File
#!/usr/bin/env bash
|
|
#MISE description="Build yuctl (embeds the linux bench agent)"
|
|
set -e
|
|
|
|
mkdir -p dist
|
|
cd packages/yuctl
|
|
|
|
# Two-stage: cross-build the bench agent, embed it (-tags embedagent) so
|
|
# `yuctl tools bench` is self-contained. Plain `go build` still works without
|
|
# the tag — the embedded agent is then absent and --agent-bin is required.
|
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o ../../dist/bench-agent-linux-amd64 ./cmd/bench-agent
|
|
gzip -9 -n -c ../../dist/bench-agent-linux-amd64 > resticbench/bench-agent-linux-amd64.gz
|
|
|
|
go build -tags embedagent -o ../../dist/yuctl .
|