dockermaveplugi是个简单的可以管理Docker容器mave插件,这个插件将会根据你的配置,在构建时启动容器,构建结束时停止容器并删除,如果本地找不到镜像,Docker会自动去中央仓库下载。
简单示例:
<plugi> <groupId>com.ofbizia</groupId> <artifactId>docker-mave-plugi</artifactId> <versio>1.0.0</versio> <cofiguratio> <images> <image> <ame>busybox</ame> </image> </images> </cofiguratio> <executios> <executio> <id>start-docker</id> <phase>pre-itegratio-test</phase> <goals> <goal>start</goal> </goals> </executio> </executios></plugi>所有可能配置的完整示例:
<plugi> <groupId>com.ofbizia</groupId> <artifactId>docker-mave-plugi</artifactId> <versio>1.0.0</versio> <cofiguratio> <dockerUrl>https://localhost:4243</dockerUrl> <images> <image> <ame>dockerfile/redis</ame> <cotaierCofig> <![CDATA[ {"Hostame":"", "PortSpecs":ull, "User":"", "Tty":false, "OpeStdi":false, "StdiOce":false, "Memory":0, "MemorySwap":0, "CpuShares":0, "AttachStdi":false, "AttachStdout":false, "AttachStderr":false, "Ev":ull, "Cmd":ull, "Ds":ull, "Volumes":ull, "VolumesFrom":"", "Etrypoit":[ ], "NetworkDisabled":false, "Privileged":false, "WorkigDir":"", "Domaiame":"", "ExposedPorts":ull, "OBuild":ull} ]]> </cotaierCofig> <hostCofig> <![CDATA[ {"CotaierIDFile": ull, "LxcCof": ull, "Liks": ull, "PortBidigs": { "6379/tcp": [ { "HostIp": "0.0.0.0", "HostPort": "6379" } ] }, "Privileged": false, "PublishAllPorts": false} ]]> </hostCofig> </image> <image> <ame>busybox</ame> </image> </images> </cofiguratio> <executios> <executio> <id>start-docker</id> <phase>pre-itegratio-test</phase> <goals> <goal>start</goal> </goals> </executio> <executio> <id>stop-docker</id> <phase>post-itegratio-test</phase> <goals> <goal>stop</goal> </goals> </executio> </executios></plugi>









评论