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

SimpleElastix docker image size #1

Open
sagarr opened this issue Sep 7, 2020 · 3 comments
Open

SimpleElastix docker image size #1

sagarr opened this issue Sep 7, 2020 · 3 comments

Comments

@sagarr
Copy link

sagarr commented Sep 7, 2020

Hi.

Sorry for raising it as an issue, but when I build docker image the size becomes 9.66 GB, Do you know what was your docker image size for elastix when you build it?

@romangrothausmann
Copy link
Owner

No, the builder image is about 1GB and the final image only about 200MB, see:
https://gitlab.com/romangrothausmann/elastix_scripts/container_registry

@sagarr
Copy link
Author

sagarr commented Sep 7, 2020

Thanks for the reply, is there any special docker build command to run.
I ran below command:
docker build --tag img-reg .

@romangrothausmann
Copy link
Owner

Thanks for the reply, is there any special docker build command to run.

Well the GL-CI runs it with stages:

## 1st stage build
- docker pull $IMAGE_TAG:system-latest || true
- docker build --pull
--cache-from $IMAGE_TAG:system-latest
--tag $IMAGE_TAG:system-latest
--target system
.
- docker push $IMAGE_TAG:system-latest
## 2nd stage build
- docker pull $IMAGE_TAG:builder-latest || true
- docker build --pull
--cache-from $IMAGE_TAG:system-latest
--cache-from $IMAGE_TAG:builder-latest
--tag $IMAGE_TAG:builder-latest
--target builder
.
- docker push $IMAGE_TAG:builder-latest
## 3rd stage build
- docker pull $IMAGE_TAG:test || true
- docker build --pull
--cache-from $IMAGE_TAG:system-latest
--cache-from $IMAGE_TAG:builder-latest
--cache-from $IMAGE_TAG:test
--tag $IMAGE_TAG:test
.
- docker push $IMAGE_TAG:test

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

No branches or pull requests

2 participants