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

FROM images in Dockerfiles specified by relative paths are not pulled when building #1823

Closed
jrnorth opened this issue Sep 21, 2024 · 0 comments · Fixed by #1824
Closed

FROM images in Dockerfiles specified by relative paths are not pulled when building #1823

jrnorth opened this issue Sep 21, 2024 · 0 comments · Fixed by #1824
Assignees

Comments

@jrnorth
Copy link
Contributor

jrnorth commented Sep 21, 2024

Description

If you point to your Dockerfile using a relative path, then any FROM images in your Dockerfile will not be pulled when using the docker:build goal.

The documentation for docker:build states:

All paths can be either absolute or relative paths (except when both dockerFileDir and dockerFile are provided in which case dockerFile must not be absolute). A relative path is looked up in ${project.basedir}/src/main/docker by default. You can make it easily an absolute path by using ${project.basedir} in your configuration.

My image's build configuration has not changed from version 0.43.4, but the FROM images in my Dockerfile are no longer pulled. Dockerfile and files.xml are both in the src/main/docker folder of my module.

<build>
    <dockerFile>Dockerfile</dockerFile>
    <assembly>
        <descriptor>files.xml</descriptor>
    </assembly>
</build>

This regression was introduced in e980189. I tested with 0.44.0 and could not reproduce the issue.

Info

  • docker-maven-plugin version : 0.45.0
  • Maven version (mvn -v) :
Apache Maven 3.9.9 (8e8579a9e76f7d015ee5ec7bfcdc97d260186937)
Maven home: /Applications/apache-maven-3.9.9
Java version: 17.0.12, vendor: Amazon.com Inc., runtime: /Library/Java/JavaVirtualMachines/amazon-corretto-17.jdk/Contents/Home
Default locale: en_US, platform encoding: UTF-8
OS name: "mac os x", version: "13.7", arch: "aarch64", family: "mac"
  • Docker version : Docker version 27.2.0, build 3ab4256
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

Successfully merging a pull request may close this issue.

1 participant