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

Fix #34 Create a RunContainersMojo that allows you to use mvn docker:run #111

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Ardesco
Copy link
Contributor

@Ardesco Ardesco commented Feb 18, 2016

This is a very basic implementation as it stands.

Right now you have a few options:

  • mvn docker:run - Start up the containers
  • mvn docker:build-images docker:run - Build missing images and start up the containers
  • mvn package docker:run - Rebuild the images and start up the containers

You could start trying to force the docker:run goal to build images as well as running them, but then you'll be duplicating parts of the build images MOJO for the config and you'll have to extract the functions it uses out into a separate class (Unless there is some Maven magic that allows you to force the run of multiple goals inside a MOJO I don't know about at the moment).

Once the containers have started the code drops into an infinite loop until CTRL + C has been pressed. You could start adding state to the containers and check that they are still in a running state instead of just having an infinite loop, or you could continually query the remote API to see if they are still up and running, but that's a bit more work (And I don't think it's really going to add much additional benefit).

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 this pull request may close these issues.

1 participant