Skip to content

Follow settings ingored unless specified from command line #1797

Closed

Description

@jakub-bochenski

Description

None of this works

            <properties>
                <docker.follow>true</docker.follow>
            </properties>
            <build>
                <pluginManagement>
                    <plugins>
                        <plugin>
                            <groupId>io.fabric8</groupId>
                            <artifactId>docker-maven-plugin</artifactId>
                            <configuration>
                                <follow>true</follow>
                            </configuration>
                        </plugin>
                    </plugins>
                </pluginManagement>
            </build>

the setting is only respected when specified from command line.

This is confusing.
Also I can't have a nice mvn -Prun command working.

Info

  • docker-maven-plugin version : 0.44

Activity

  1. rohanKanojia commented on Jun 26, 2024

    @rohanKanojia
    Member

    @jakub-bochenski : Would it be possible for you to debug this? Could you please run mvnDebug docker:log and then set a breakpoint here and connect from your IDE as JVM debug

  2. jakub-bochenski commented on Nov 25, 2024

    @jakub-bochenski
    ContributorAuthor

    I'm after the StartMojo, not LogsMojo

    Looking at the code it becomes obvious that only a system property is supported and not maven configuration.
    But why? Can it be changed?

    https://github.com/fabric8io/docker-maven-plugin/blob/v0.45.1/src/main/java/io/fabric8/maven/docker/StartMojo.java#L223

  3. jakub-bochenski commented on Nov 25, 2024

    @jakub-bochenski
    ContributorAuthor

    This is the workaround I use for now

                        <plugin>
                            <!-- https://github.com/fabric8io/docker-maven-plugin/issues/1797 -->
                            <groupId>org.codehaus.mojo</groupId>
                            <artifactId>properties-maven-plugin</artifactId>
                            <executions>
                                <execution>
                                    <goals>
                                        <goal>set-system-properties</goal>
                                    </goals>
                                    <configuration>
                                        <properties>
                                            <property>
                                                <name>docker.follow</name>
                                                <value>true</value>
                                            </property>
                                        </properties>
                                    </configuration>
                                </execution>
                            </executions>
                        </plugin>
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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