changelog shortlog graph tags branches changeset file revisions annotate raw help

Mercurial > demo / Dockerfile

revision 22: ba323d8c0f93
parent 20: 3166a511fafb
     1.1--- a/Dockerfile	Sat Jun 03 19:57:46 2023 -0400
     1.2+++ b/Dockerfile	Sat Jun 03 22:48:46 2023 -0400
     1.3@@ -1,38 +1,10 @@
     1.4-ARG ROSWELL_IMAGE=fukamachi/roswell
     1.5-ARG ROSWELL_VERSION
     1.6-ARG OS=debian
     1.7-FROM fukamachi/roswell:latest-$OS AS build-env
     1.8-ARG OS
     1.9+ARG OS=archlinux
    1.10 ARG VERSION
    1.11 ADD https://github.com/sbcl/sbcl/archive/sbcl-$VERSION.tar.gz sbcl.tar.gz
    1.12 
    1.13 RUN set -x; \
    1.14-  arch="$(case $(uname -m) in amd64|x86_64) echo x86-64;; aarch64) echo arm64;; *) uname -m ;; esac)"; \
    1.15-  if [ "$OS" = "alpine" ]; then \
    1.16-    apk add --update build-base linux-headers zstd-dev; \
    1.17-  else \
    1.18-    apt-get update && apt-get -y install --no-install-recommends \
    1.19-      build-essential \
    1.20-      zlib1g-dev \
    1.21-      libzstd-dev \
    1.22-      time; \
    1.23-  fi; \
    1.24-  ros install sbcl-bin/2.2.7 && \
    1.25   tar xvfz sbcl.tar.gz && rm sbcl.tar.gz && cd "sbcl-sbcl-${VERSION}" && \
    1.26-  echo "\"$VERSION\"" > version.lisp-expr && \
    1.27-  (sh make.sh \
    1.28-      --with-sb-core-compression \
    1.29-      "--xc-host=ros -L sbcl-bin without-roswell=t --no-rc run" \
    1.30-      "--prefix=$HOME/.roswell/impls/$arch/linux/sbcl-bin/$VERSION/" || true) \
    1.31-    && sh install.sh && \
    1.32-    rm -f "/root/.roswell/impls/$arch/linux/sbcl-bin/$VERSION/lib/sbcl/sbcl.core.old" \
    1.33-      && rm -f "/root/.roswell/impls/$arch/linux/sbcl-bin/$VERSION/bin/sbcl.old" \
    1.34-      && find "/root/.roswell/impls/$arch/linux/sbcl-bin" -maxdepth 1 -mindepth 1 | grep -v "/sbcl-bin/$VERSION$" | xargs rm -rf || true \
    1.35-      && rm -rf "/root/.roswell/impls/log"
    1.36-
    1.37-FROM $ROSWELL_IMAGE:$ROSWELL_VERSION-$OS
    1.38-# hadolint ignore=DL3010
    1.39-COPY --from=build-env /root/.roswell/impls /root/.roswell/impls
    1.40+  echo "\"$VERSION\"" > version.s && \
    1.41 
    1.42 ARG BUILD_DATE
    1.43 ARG VCS_REF
    1.44@@ -41,25 +13,7 @@
    1.45 
    1.46 LABEL org.label-schema.build-date=$BUILD_DATE \
    1.47       org.label-schema.vcs-ref=$VCS_REF \
    1.48-      org.label-schema.vcs-url="https://github.com/fukamachi/dockerfiles" \
    1.49       org.label-schema.version=$VERSION \
    1.50       org.label-schema.schema-version="1.0"
    1.51 
    1.52-# hadolint ignore=DL3018
    1.53-RUN set -x; \
    1.54-  if [ "$OS" = "alpine" ]; then \
    1.55-    apk add --update --no-cache zstd-libs; \
    1.56-  fi; \
    1.57-  printf "setup.time\t0\t%s\n" "$(( $(date +%s) + 2208988800 ))" > ~/.roswell/config && \
    1.58-  printf "sbcl-bin.version\t0\t%s\n" "$VERSION" >> ~/.roswell/config && \
    1.59-  printf "default.lisp\t0\tsbcl-bin\n" >> ~/.roswell/config && \
    1.60-  ros setup && \
    1.61-  ros -e '(mapc (function ql-dist:uninstall) (ql-dist:installed-releases t))' \
    1.62-    && rm -f /root/.roswell/lisp/quicklisp/tmp/quicklisp.tar \
    1.63-    && rm -rf /root/.roswell/archives/* /root/.roswell/src/sbcl-* /root/.cache/common-lisp/sbcl-*/root/.roswell/lisp/quicklisp/dists/quicklisp/software
    1.64-
    1.65-RUN set -x; \
    1.66-  printf '#!/bin/sh\nexec ros run -- "$@"\n' > /usr/local/bin/sbcl \
    1.67-  && chmod u+x /usr/local/bin/sbcl
    1.68-
    1.69 ENTRYPOINT ["/usr/local/bin/sbcl"]
    1.70\ No newline at end of file