Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mint build fails when running in Bitbucket pipelines #95

Open
NilsMoller opened this issue Jan 13, 2025 · 0 comments
Open

Mint build fails when running in Bitbucket pipelines #95

NilsMoller opened this issue Jan 13, 2025 · 0 comments

Comments

@NilsMoller
Copy link

NilsMoller commented Jan 13, 2025

Expected Behavior

  1. Push a commit to Bitbucket and trigger the pipeline.
  2. Install Mint using the installer script.
  3. Run mint build node:20
  4. End up with an optimized image.

Actual Behavior

  1. Push a commit to Bitbucket and trigger the pipeline.
  2. Install Mint using the installer script.
  3. Run mint build node:20
  4. Get the following output:
+ mint build node:20

cmd=slim info=param.http.probe message='using default probe' 

cmd=slim state=started

cmd=slim info=cmd.input.params keep.perms='true' tags='' image-build-engine='internal' target.type='image' target.image='node:20' continue.mode='probe' rt.as.user='true' 

cmd=slim state=image.inspection.start

cmd=slim info=image id='sha256:7b632d45f5d2dd638495dfdfaac7c663133e31a39e8931f8857ab6575075aaa4' size.bytes='0' size.human='0 B' 

cmd=slim info=image.stack name='node:20' id='sha256:7b632d45f5d2dd638495dfdfaac7c663133e31a39e8931f8857ab6575075aaa4' index='0' 

cmd=slim state=image.inspection.done

cmd=slim state=container.inspection.start

time="2025-01-13T08:30:03Z" level=error msg="dockerutil.BuildEmptyImage: dockerapi.BuildImage() error = API error (400): client version 1.12 is too old. Minimum supported API version is 1.24, please upgrade your client to a newer version\n / output: "

time="2025-01-13T08:30:03Z" level=fatal msg="slim: failure" error="API error (400): client version 1.12 is too old. Minimum supported API version is 1.24, please upgrade your client to a newer version\n" stack="goroutine 1 [running]:\nruntime/debug.Stack()\n\truntime/debug/stack.go:26 +0x5e\[ngithub.com/mintoolkit/mint/pkg/util/errutil.FailOn](http://ngithub.com/mintoolkit/mint/pkg/util/errutil.FailOn)({0x2f5b560, 0xc000a80180})\n\[tgithub.com/mintoolkit/mint/pkg/util/errutil/errutil.go:32](http://tgithub.com/mintoolkit/mint/pkg/util/errutil/errutil.go:32) +0x4b\[ngithub.com/mintoolkit/mint/pkg/app/master/inspectors/container.(*Inspector](http://ngithub.com/mintoolkit/mint/pkg/app/master/inspectors/container.(*Inspector)).RunContainer(0xc00024bb08)\n\[tgithub.com/mintoolkit/mint/pkg/app/master/inspectors/container/container_inspector.go:439](http://tgithub.com/mintoolkit/mint/pkg/app/master/inspectors/container/container_inspector.go:439) +0x757\[ngithub.com/mintoolkit/mint/pkg/app/master/command/build.OnCommand](http://ngithub.com/mintoolkit/mint/pkg/app/master/command/build.OnCommand)(_, _, {_, _}, _, {_, _}, {_, _}, {0x0, ...}, ...)\n\[tgithub.com/mintoolkit/mint/pkg/app/master/command/build/handler.go:1141](http://tgithub.com/mintoolkit/mint/pkg/app/master/command/build/handler.go:1141) +0x4575\[ngithub.com/mintoolkit/mint/pkg/app/master/command/build.init.func1(0xc000278780)\n\tgithub.com/mintoolkit/mint/pkg/app/master/command/build/cli.go:780](http://ngithub.com/mintoolkit/mint/pkg/app/master/command/build.init.func1(0xc000278780)/n/tgithub.com/mintoolkit/mint/pkg/app/master/command/build/cli.go:780) +0x5cb0\[ngithub.com/urfave/cli/v2.(*Command](http://ngithub.com/urfave/cli/v2.(*Command)).Run(0x4685dc0, 0xc000278780, {0xc000276780, 0x2, 0x2})\n\[tgithub.com/urfave/cli/[email protected]/command.go:279](http://tgithub.com/urfave/cli/[email protected]/command.go:279) +0x7e2\[ngithub.com/urfave/cli/v2.(*Command](http://ngithub.com/urfave/cli/v2.(*Command)).Run(0xc0002cfce0, 0xc0002781c0, {0xc000050140, 0x4, 0x4})\n\[tgithub.com/urfave/cli/[email protected]/command.go:272](http://tgithub.com/urfave/cli/[email protected]/command.go:272) +0xa65\[ngithub.com/urfave/cli/v2.(*App](http://ngithub.com/urfave/cli/v2.(*App)).RunContext(0xc00027c400, {0x2f85598, 0x4705340}, {0xc000050140, 0x4, 0x4})\n\[tgithub.com/urfave/cli/[email protected]/app.go:337](http://tgithub.com/urfave/cli/[email protected]/app.go:337) +0x58b\[ngithub.com/urfave/cli/v2.(*App](http://ngithub.com/urfave/cli/v2.(*App)).Run(...)\n\[tgithub.com/urfave/cli/[email protected]/app.go:311\ngithub.com/mintoolkit/mint/pkg/app/master.Run()\n\tgithub.com/mintoolkit/mint/pkg/app/master/app.go:15](http://tgithub.com/urfave/cli/[email protected]/app.go:311/ngithub.com/mintoolkit/mint/pkg/app/master.Run()/n/tgithub.com/mintoolkit/mint/pkg/app/master/app.go:15) +0x45\nmain.main()\n\[tgithub.com/mintoolkit/mint/cmd/mint/main.go:15](http://tgithub.com/mintoolkit/mint/cmd/mint/main.go:15) +0x187\n" version="linux/amd64|Aurora|1.41.7|a2a53d2348aeedf0d650d47debf477a2cad47111|2024-09-25_03:07:42PM"

Steps to Reproduce the Problem

The following all runs in a Bitbucket pipeline

  1. Install Mint: curl -sL https://raw.githubusercontent.com/mintoolkit/mint/master/scripts/install-mint.sh | bash - (in Bitbucket pipelines you cannot use sudo, but the installation completes successfully).
  2. Verify installation: mint --version to see it is running on the version specified below.
  3. Run docker pull node:20 to pull the Docker image to optimize.
  4. Run mint on a Docker image: mint build node:20
  5. See the error.

Extra details

There was already an issue discussing this in the Slim repository: slimtoolkit/slim#646


Specifications

  • Version: mint version linux/amd64|Aurora|1.41.7|a2a53d2348aeedf0d650d47debf477a2cad47111|2024-09-25_03:07:42PM
  • Platform: Bitbucket pipelines with node:22.12.0 as base image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant