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

feat: Refactor Dockerfile #3372

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open

Commits on May 4, 2024

  1. feat: Refactor Dockerfile

    - Simplify and reduce layers where possible via HEREDOC syntax for `RUN` statements + DRY `COPY`.
    - `--target` is redundant during rustup install, instead only handle via `rustup target add`.
    - Shift order of directives such as ENV to minimize layers invalidated.
    polarathene authored May 4, 2024
    Configuration menu
    Copy the full SHA
    39fcccb View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    063a9be View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    a314ed9 View commit details
    Browse the repository at this point in the history
  4. chore: Alternative - Diverge image at build-time

    This may be easier to grok, avoiding the loop to build concurrently instead. Introduces more stages with fixed ENV instead of prior conditional branch with txt file. Still shares a common base with both target triples installed.
    polarathene authored May 4, 2024
    Configuration menu
    Copy the full SHA
    2d4e856 View commit details
    Browse the repository at this point in the history
  5. feat: Optimize binary size

    Brings the binary down to 24MB (AMD64) and 21MB (ARM64), reducing binary size by more than 70%. This could be further reduced.
    polarathene authored May 4, 2024
    Configuration menu
    Copy the full SHA
    d352b09 View commit details
    Browse the repository at this point in the history