From 38eb6c94131a6d94924f698056834908d35ff626 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eug=C3=A9n=20Cowie?= Date: Fri, 27 Sep 2024 09:27:21 +0100 Subject: [PATCH] Use PATH instead of symlink MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Eugén Cowie --- pkg/docker-compose/build.go | 2 +- pkg/docker-compose/build_test.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/docker-compose/build.go b/pkg/docker-compose/build.go index 5bd4a1b..d23db02 100644 --- a/pkg/docker-compose/build.go +++ b/pkg/docker-compose/build.go @@ -44,7 +44,7 @@ func (m *Mixin) Build(ctx context.Context) error { } dockerfileLines := fmt.Sprintf(`ADD --chmod=755 https://github.com/docker/compose/releases/download/v%s/docker-compose-linux-x86_64 /usr/local/lib/docker/cli-plugins/docker-compose -RUN ln -s /usr/local/lib/docker/cli-plugins/docker-compose /usr/local/bin/docker-compose`, dockerComposeVersion) +ENV PATH="$PATH:/usr/local/lib/docker/cli-plugins"`, dockerComposeVersion) fmt.Fprintln(m.Out, dockerfileLines) diff --git a/pkg/docker-compose/build_test.go b/pkg/docker-compose/build_test.go index 8819334..70826ac 100644 --- a/pkg/docker-compose/build_test.go +++ b/pkg/docker-compose/build_test.go @@ -12,7 +12,7 @@ import ( func TestMixin_Build(t *testing.T) { const buildOutput = `ADD --chmod=755 https://github.com/docker/compose/releases/download/v2.10.2/docker-compose-linux-x86_64 /usr/local/lib/docker/cli-plugins/docker-compose -RUN ln -s /usr/local/lib/docker/cli-plugins/docker-compose /usr/local/bin/docker-compose +ENV PATH="$PATH:/usr/local/lib/docker/cli-plugins" ` t.Run("build", func(t *testing.T) {