Skip to content

Instantly share code, notes, and snippets.

@finestructure
Last active February 3, 2024 09:58
Show Gist options
  • Save finestructure/7d99984f744dc9f36da7b1f26def4525 to your computer and use it in GitHub Desktop.
Save finestructure/7d99984f744dc9f36da7b1f26def4525 to your computer and use it in GitHub Desktop.
Pkl dockerfile
FROM swift:5.9-slim
RUN apt-get update && apt-get -y install curl fish
ARG PKL_VERSION=0.25.1
RUN curl -L -o /usr/local/bin/pkl https://github.com/apple/pkl/releases/download/${PKL_VERSION}/pkl-linux-aarch64 && chmod +x /usr/local/bin/pkl
# requires Swift runtime libraries, that's why the base image is swift:5.9-slim
ARG PKL_GEN_SWIFT_VERSION=0.2.1
RUN curl -L -o /usr/local/bin/pkl-gen-swift https://github.com/apple/pkl-swift/releases/download/${PKL_GEN_SWIFT_VERSION}/pkl-gen-swift-linux-aarch64.bin && chmod +x /usr/local/bin/pkl-gen-swift
@finestructure
Copy link
Author

finestructure commented Feb 3, 2024

Usage:

docker build -t pkl -f Dockerfile
docker run --rm -it -v $PWD:/host -w /host --entrypoint bash pkl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment