Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Very small rust docker image

License

NotificationsYou must be signed in to change notification settings

kpcyrd/mini-docker-rust

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Very small rust docker image.

This is an example project on how to build very small docker images for a rust project. The resulting image for a workinghello world was 5.69MB in the case of Alpine 3.16. Alpine versions have changed in size with past releases (see below a table with historic sizes of the docker images). Using end-of-life Alpine/Rust releases is not advised (even if they might be slightly smaller). Checked sizes withdocker system df -v

AlpineSize
alpine:3.198.22MB
alpine:3.188.22MB
alpine:3.177.95MB
alpine:3.165.69MB
alpine:3.155.74MB
alpine:3.145.73MB

This repo is trying to keep the docker overhead to a minimum without sacrificing performance or the usability implications of usingFROM scratch. If you want to reduce the binary size further you might be interested injohnthagen/min-sized-rust.

See for yourself

You don't need to install anything besides docker. Build withdocker build -t mini-docker-rust . and run withdocker run mini-docker-rust.

Annotated docker file

SeeDockerfile.

About

Very small rust docker image

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors4

  •  
  •  
  •  
  •  

[8]ページ先頭

©2009-2025 Movatter.jp