spotify / docker-maven-plugin

INACTIVE: A maven plugin for Docker
Apache License 2.0
2.67k stars 575 forks source link

I want execute this plugin in the parent project of maven ,but it appears that the parent project of target folder is not exist.how can I use the plugin to batch execute docker:build #356

Closed 13567436138 closed 6 years ago

13567436138 commented 7 years ago

[INFO] cloud-docker-parent ................................ FAILURE [ 46.177 s] [INFO] cloud-docker-common ................................ SKIPPED [INFO] cloud-docker-menu-api .............................. SKIPPED [INFO] cloud-docker-user-api .............................. SKIPPED [INFO] cloud-docker-resource-api .......................... SKIPPED [INFO] cloud-docker-front-end ............................. SKIPPED [INFO] cloud-docker-admin-server .......................... SKIPPED [INFO] cloud-docker-config ................................ SKIPPED [INFO] cloud-docker-eureka ................................ SKIPPED [INFO] cloud-docker-hystrix-turbine ....................... SKIPPED [INFO] cloud-docker-menu-service .......................... SKIPPED [INFO] cloud-docker-redis-service ......................... SKIPPED [INFO] cloud-docker-resource-service ...................... SKIPPED [INFO] cloud-docker-user-service .......................... SKIPPED [INFO] cloud-docker-zipkin-server ......................... SKIPPED [INFO] cloud-docker-zuul .................................. SKIPPED [INFO] ------------------------------------------------------------------------ [INFO] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] Total time: 05:06 min [INFO] Finished at: 2017-10-29T18:33:16+08:00 [INFO] Final Memory: 67M/425M [INFO] ------------------------------------------------------------------------ [ERROR] Failed to execute goal com.spotify:docker-maven-plugin:1.0.0:build (default-cli) on project cloud-docker-parent: Exception caught: basedir D:\working\workspace_tz_myeclipse\spring-cloud-demo\cloud-docker-parent\target does not exist -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch. [ERROR] Re-run Maven using the -X switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

mattnworb commented 6 years ago

This has more to do with the best way to configure plugins when using multimodule builds in Maven, and not related to this plugin per se. See https://stackoverflow.com/questions/12924634/define-maven-plugins-in-parent-pom-but-only-invoke-plugins-in-child-projects as an example of a few ways to accomplish this.