trunk icon indicating copy to clipboard operation
trunk copied to clipboard

Consider adding a docker file

Open EvanCarroll opened this issue 7 months ago • 1 comments

It may be a good idea to add a simple Dockerfile to the repo, that has trunk preinstalled two major benefits here.

  • Faster to not have to build trunk for a ci run
  • You don't download rust-std for wasm32-unknown-unknown

You can use the ghcr.io or dockerhub.io to store the image.

FROM rust:slim

# Install dependencies
RUN apt-get update && apt-get install -y pkg-config

# Add wasm target
RUN rustup target add wasm32-unknown-unknown

# Install trunk
RUN cargo install trunk

# Set working directory
WORKDIR /app

consider my use case, I'm building cicd for a repo that has a leptos project. I need to produce a zip with the static assets.

EvanCarroll avatar Apr 22 '25 19:04 EvanCarroll

True, what would be a great idea.

ctron avatar Apr 24 '25 06:04 ctron