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

Idea to optimize images #694

Open
GurliGebis opened this issue Oct 29, 2021 · 0 comments
Open

Idea to optimize images #694

GurliGebis opened this issue Oct 29, 2021 · 0 comments

Comments

@GurliGebis
Copy link

ISSUE

Currently, every image (cm, cd, rep etc.) are created from scratch, resulting in a huge download when downloading the images.
An idea might be to use a multistage image, and then have a stage where a sitecore instance is copied into the resulting image.
Then after that, App_Config and Web.config is overwritten by the version that matches the correct Sitecore role.

If you do it this way, there will be a layer containing all the sitecore files that will only be downloaded once, and then a separate small layer for each of the roles, improving download speed, storage requirements and load on the container registry.

My idea would be like this:

1: First copy files for the CM role into the destination C:\inetpub\wwwroot in the Dockerfile
2: Then, in a separate command in the Dockerfile for all of the roles, copy the App_Config and Web.config for that role into the folder, overwriting the files from the CM instance.

By doing it this way, everything should be smaller.
From what I can see when downloading the images, there is no optimization for this (please correct me if I'm wrong, since I cannot find the sitecore assets image anywhere to inspect).

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

1 participant