Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 2 additions & 0 deletions .nuke/build.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@
"PackChocolateyPackage",
"PackClient",
"PackContracts",
"PackCore",
"PackCrossPlatformBundle",
"PackDebianPackage",
"PackLinux",
Expand Down Expand Up @@ -172,6 +173,7 @@
"PackChocolateyPackage",
"PackClient",
"PackContracts",
"PackCore",
"PackCrossPlatformBundle",
"PackDebianPackage",
"PackLinux",
Expand Down
10 changes: 5 additions & 5 deletions docker/kubernetes-agent-tentacle/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
ARG RuntimeDepsTag


FROM golang:1.22 as bootstrapRunnerBuilder
FROM golang:1.24 AS bootstrapRunnerBuilder

ARG TARGETARCH
ARG TARGETOS
Expand All @@ -10,8 +9,8 @@ COPY docker/kubernetes-agent-tentacle/bootstrapRunner/* /bootstrapRunner/
WORKDIR /bootstrapRunner

# Note: the given ldflags remove debug symbols
RUN go build -ldflags "-s -w" -o "bin/bootstrapRunner"

RUN env GOOS=linux GOARCH=amd64 go build -ldflags "-s -w" -o "bin/bootstrapRunner-amd64"
RUN env GOOS=linux GOARCH=arm64 go build -ldflags "-s -w" -o "bin/bootstrapRunner-arm64"

FROM mcr.microsoft.com/dotnet/runtime-deps:$RuntimeDepsTag

Expand All @@ -24,7 +23,8 @@ ARG TARGETVARIANT
EXPOSE 10933

COPY docker/kubernetes-agent-tentacle/scripts/* /scripts/
COPY --from=bootstrapRunnerBuilder bootstrapRunner/bin/bootstrapRunner /bootstrapRunner
COPY --from=bootstrapRunnerBuilder bootstrapRunner/bin/bootstrapRunner-amd64 /bootstrapRunner-amd64
COPY --from=bootstrapRunnerBuilder bootstrapRunner/bin/bootstrapRunner-arm64 /bootstrapRunner-arm64
RUN chmod +x /scripts/*.sh

WORKDIR /tmp
Expand Down
7 changes: 3 additions & 4 deletions docker/kubernetes-agent-tentacle/dev/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
ARG RuntimeDepsTag


FROM golang:1.22 as bootstrapRunnerBuilder
FROM golang:1.24 AS bootstrapRunnerBuilder

ARG TARGETARCH
ARG TARGETOS
Expand All @@ -10,8 +9,8 @@ COPY docker/kubernetes-agent-tentacle/bootstrapRunner/* /bootstrapRunner/
WORKDIR /bootstrapRunner

# Note: the given ldflags remove debug symbols
RUN go build -ldflags "-s -w" -o "bin/bootstrapRunner"

RUN env GOOS=linux GOARCH=amd64 go build -ldflags "-s -w" -o "bin/bootstrapRunner/amd64"
RUN env GOOS=linux GOARCH=arm64 go build -ldflags "-s -w" -o "bin/bootstrapRunner/arm64"

FROM mcr.microsoft.com/dotnet/runtime-deps:$RuntimeDepsTag

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,8 @@ async Task CreatePod(StartKubernetesScriptCommandV1 command, IScriptWorkspace wo

LogVerboseToBothLogs($"Creating Kubernetes Pod '{podName}'.", tentacleScriptLog);

workspace.CopyFile(KubernetesConfig.BootstrapRunnerExecutablePath, "bootstrapRunner", true);
workspace.CopyFile($"{KubernetesConfig.BootstrapRunnerExecutablePath}-amd64", "bootstrapRunner-amd64", true);
workspace.CopyFile($"{KubernetesConfig.BootstrapRunnerExecutablePath}-arm64", "bootstrapRunner-arm64", true);

var scriptName = Path.GetFileName(workspace.BootstrapScriptFilePath);
var workspacePath = Path.Combine("Work", workspace.ScriptTicket.TaskId);
Expand Down Expand Up @@ -292,7 +293,7 @@ protected async Task<V1Container> CreateScriptContainer(StartKubernetesScriptCom

var commandString = string.Join(" ", new[]
{
$"{homeDir}/Work/{command.ScriptTicket.TaskId}/bootstrapRunner",
$"{homeDir}/Work/{command.ScriptTicket.TaskId}/bootstrapRunner-$(arch | sed -n '/arm/ {{s/.*arm.*/arm/;p;q}}; $a\\amd64')",
Path.Combine(homeDir, workspacePath),
Path.Combine(homeDir, workspacePath, scriptName)
}.Concat(scriptArguments ?? Array.Empty<string>())
Expand Down