You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I can do a PR, but wanted to ask this as a question first. I want to build a custom st2 base image and then build the remaining st2 images from that image instead of upstream stackstorm/st2:${ST2_VERSION}
For background, I went to build the docker images myself in order to get bionic/python3.6 (see #16), which required making changes to the base image. I want to give the st2 base image and all subsequent ones a tag of "3.2.0-dev-bionic", which I can do by exporting DOCKER_TAG before running "make build".
The problem is that each Dockerfile has a line of FROM stackstorm/st2:${ST2_VERSION}. Which means they won't build from my new base image, but rather upstream base image.
My workaround is to additionally pass DOCKER_TAG into each Dockerfile and update the from line.
ARG ST2_VERSION
ARG DOCKER_TAG
FROM stackstorm/st2:${DOCKER_TAG}
Then in the Makefile:
for component in st2*; do \
docker build \
--no-cache \
--build-arg ST2_VERSION=${ST2_VERSION} \
--build-arg DOCKER_TAG=${DOCKER_TAG} \
--tag stackstorm/$$component:${DOCKER_TAG} \
This seems reasonable to me. If someone is needing to put a specific tag on the base, they will most likely want to build their other images from that tag. If this seems reasonable or useful to others, I will go ahead and create a PR.
The text was updated successfully, but these errors were encountered:
I can do a PR, but wanted to ask this as a question first. I want to build a custom st2 base image and then build the remaining st2 images from that image instead of upstream
stackstorm/st2:${ST2_VERSION}
For background, I went to build the docker images myself in order to get bionic/python3.6 (see #16), which required making changes to the base image. I want to give the st2 base image and all subsequent ones a tag of "3.2.0-dev-bionic", which I can do by exporting DOCKER_TAG before running "make build".
The problem is that each Dockerfile has a line of
FROM stackstorm/st2:${ST2_VERSION}
. Which means they won't build from my new base image, but rather upstream base image.My workaround is to additionally pass DOCKER_TAG into each Dockerfile and update the from line.
Then in the Makefile:
This seems reasonable to me. If someone is needing to put a specific tag on the base, they will most likely want to build their other images from that tag. If this seems reasonable or useful to others, I will go ahead and create a PR.
The text was updated successfully, but these errors were encountered: