Optimizing Docker container for MATLAB Runtime R2020b - help needed

Hello,
I need help optimizing a Docker container for MATLAB Runtime R2020b (v9.9). Mathworks provides optimized container images through Docker Hub repository (using docker pull containers.mathworks.com/matlab-runtime:<tag>), but these seems to be only available from R2021b onwards.
My attempt at creating a custom container has resulted in an image with a few extremely large layers that are impractical for deployment. Has anyone successfully created an optimized Docker container for MATLAB Runtime R2020b (v9.9) ?
Has anyone successfully created an optimized Docker container for MATLAB Runtime R2020b (v9.9)? I'm particularly interested in:
  • Strategies for reducing image size
  • Best practices for MCR containerization
  • Examples of optimized Dockerfiles for older MCR versions
Any guidance or examples would be greatly appreciated. Thanks for your help.

댓글 수: 1

I do not have any experience with this but am wanting to learn from yours. How large is too large? Or what would be optimal?
Are you doing all the toolboxes or just a select few?

댓글을 달려면 로그인하십시오.

답변 (1개)

Jacob Mathew
Jacob Mathew 2025년 6월 10일

0 개 추천

Hey Thomas,
I came across MathWorks official GitHub page that goes into details on how to create a MATLAB Container Image based on the version, products and support packages as needed:
Specifically, the product versions go as far back as R2019b and should satisfy your requirement for R202b. Here are the list of Dockerfile and dependencies for each version:

카테고리

도움말 센터File Exchange에서 Containers에 대해 자세히 알아보기

제품

릴리스

R2020b

질문:

2024년 12월 7일

답변:

2025년 6월 10일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by