We are using Bamboo to build and deploy a number of Java web applications. Right now, the Build Plans generally produce a WAR file, which is deployed by the Deploy Plans. We are moving our hosting (and building) to docker, and I'm unclear on the best way to handle this in Bamboo. Specifically, I'm unsure of whether the Build Plan or Deploy Plan should be responsible for generating a docker image.
- The Bamboo build plan does a multi-stage Docker build to tag and publish a docker image (~ 300MB)
- The Bamboo deploy plan is responsible for spinning up a container for that image.
- The Bamboo build plan does a Docker build, and attaches the artifact (WAR file ~ 80 MB)
- The Bamboo deploy plan is responsible for creating an image, inserting the WAR file, and spinning up a container
Just wondering if there is a standard or best practice pattern here. Or am I thinking about this wrong? Are there other options I should be considering?