Skip to content

When using buildx getting "Head "https://gitlab..../manifests/latest": dial tcp ...:5050: connect: connection refused"  #1841

@oktayderman

Description

@oktayderman

When running docker:build goal I am getting error below for our private registry.
We are using baseImage from our private registry in DockerFile
FROM gitlab....:5050/v2/i2i/ocs/fizz/fizz-source/base-image-17-jre/:latest

--Head "https://gitlab....:5050/v2/i2i/ocs/fizz/fizz-source/base-image-17-jre/manifests/latest": dial tcp 195.214.161.37:5050: connect: connection refused--

it works when not using buildx.

goal executing this command:
docker --config /myData/dev/projects/fizz-source/AOM/aom-parent/aomif/target/docker/aomif-maven/docker buildx build --progress=plain --platform linux/amd64 --tag aomif-maven:latest --tag aomif-maven:latest --tag aomif-maven:20.0-SNAPSHOT --file=/myData/dev/projects/fizz-source/AOM/aom-parent/aomif/target/docker/aomif-maven/tmp/docker-build/Dockerfile /myData/dev/projects/fizz-source/AOM/aom-parent/aomif/target/docker/aomif-maven/tmp/docker-build --load

if I remove --builder maven or both --config ... --builder maven of from command and run it manually from terminal. it is working.
What should I do for this error in configuration or is it a bug ?

Seems at these link guys had the same problem
#1583
#1673

I am using buildOptions with version=2 to overcome the issue to use buildkit without buildx configuration.

<image> <name>${project.artifactId}-maven</name> <alias>${project.artifactId}</alias> <build> <buildOptions> <version>2</version><!-- enable buildkit--> </buildOptions>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions