Is it possible to build multiple docker images based on one repository?
For example say I have the following:
/Dockerfile
/bitbucket-pipelines.yml
/app/app.js
/bot/Dockerfile
/bot/bot.js
I want to build one or both (depending on tags, but will accept both or a specific one based on settings) the `/Dockerfile` and the `/bot/Dockerfile` images.
Is that possible? I have the `/Dockerfile` building properly, but can't figure out how to build the bot also.
my current pipeline file:
pipelines:
default:
- step:
caches:
# This can probably be removed
- node
script: # Modify the commands below to build your repository.
# authenticate with the Azure Container registry
- docker login https://my-repo -u $DOCKER_USERNAME -p $DOCKER_PASSWORD
- export IMAGE_NAME=my-repo/my-app:${BITBUCKET_BRANCH}${BITBUCKET_BUILD_NUMBER}
# build the Docker image (this will use the Dockerfile in the root of the repo)
- docker build -t $IMAGE_NAME .
# push the new Docker image to the Docker registry
- docker push $IMAGE_NAME
options:
docker: true
Thanks!