What part of the Bamboo pipeline should generate a Docker image? 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.
Option 1

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.

Option 2

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?
I believe both options are viable routes, but my preference is for Option 1 as I like having the &quot;deploy plan&quot; to be only concerned with starting a container using the built image.