Commit c270b7e7 authored by Eric Timmons's avatar Eric Timmons
Browse files

Initial commit

parents
Copyright (c) 2018, Eric Timmons
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\ No newline at end of file
LATEST_VERSION = 1.11.5
VERSIONS = $(notdir $(shell find versions -mindepth 1 -maxdepth 1 -type d))
LATEST_DEBIAN = debian-stretch
LATEST_UBUNTU = ubuntu-cosmic
OSES = debian-stretch ubuntu-bionic ubuntu-cosmic
ALL_TARGETS =
ALL_TAGS =
all:
define DOCKER_TEMPLATE =
v$(1)-$(2):: versions/$(1)/$(2)/Dockerfile
docker build -t daewok/ccl:$(1)-$(2) versions/$(1)/$(2)
ALL_TARGETS += v$(1)-$(2)
ALL_TAGS += $(1)-$(2)
.PHONY: v$(1)-$(2)
endef
define LATEST_DEBIAN_TEMPLATE =
v$(1)-debian: v$(1)-$(LATEST_DEBIAN)
docker tag daewok/ccl:$(1)-$(LATEST_DEBIAN) daewok/ccl:$(1)-debian
ALL_TARGETS += v$(1)-debian
ALL_TAGS += $(1)-debian
.PHONY: v$(1)-debian
endef
define LATEST_UBUNTU_TEMPLATE =
v$(1)-ubuntu: v$(1)-$(LATEST_UBUNTU)
docker tag daewok/ccl:$(1)-$(LATEST_UBUNTU) daewok/ccl:$(1)-ubuntu
ALL_TARGETS += v$(1)-ubuntu
ALL_TAGS += $(1)-ubuntu
.PHONY: v$(1)-ubuntu
endef
define EXPAND_VERSION =
$(foreach os,$(OSES),$(eval $(call DOCKER_TEMPLATE,$(1),$(os))))
$(eval $(call LATEST_DEBIAN_TEMPLATE,$(1)))
$(eval $(call LATEST_UBUNTU_TEMPLATE,$(1)))
endef
define EXPAND_OS =
$(1): v$(LATEST_VERSION)-$(1)
docker tag daewok/ccl:$(LATEST_VERSION)-$(1) daewok/ccl:$(1)
.PHONY: $(1)
ALL_TARGETS += $(1)
ALL_TAGS += $(1)
endef
$(foreach v,$(VERSIONS),$(call EXPAND_VERSION,$(v)))
$(foreach o,$(OSES),$(eval $(call EXPAND_OS,$(o))))
debian-latest: v$(LATEST_VERSION)-$(LATEST_DEBIAN)
docker tag daewok/ccl:$(LATEST_VERSION)-$(LATEST_DEBIAN) daewok/ccl:debian
ubuntu-latest: v$(LATEST_VERSION)-$(LATEST_UBUNTU)
docker tag daewok/ccl:$(LATEST_VERSION)-$(LATEST_UBUNTU) daewok/ccl:ubuntu
latest: debian-latest
docker tag daewok/ccl:debian daewok/ccl:latest
ALL_TAGS += debian ubuntu latest
all: debian-latest ubuntu-latest latest $(ALL_TARGETS)
all_tags:
@echo $(ALL_TAGS)
push: all
for tag in $(ALL_TAGS) ; do \
docker push daewok/ccl:$$tag ; \
done
.PHONY: all all_tags latest push
#+TITLE: CCL Docker Images
#+AUTHOR: Eric Timmons
This repo contains Dockerfiles for Clozure Common Lisp (CCL) on a variety of
base images.
The CCL versions built are:
+ 1.11.5
The OSes and versions CCL is built on are:
+ debian
+ stretch
+ ubuntu
+ cosmic
+ bionic
* Building
To build all images, just run:
#+begin_src shell
make
#+end_src
FROM debian:stretch
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxx86.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl64 /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxx86.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
FROM ubuntu:bionic
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxx86.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl64 /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxx86.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
FROM ubuntu:cosmic
LABEL maintainer="etimmons@mit.edu"
ENV CCL_VERSION=1.11.5
WORKDIR /usr/local/src/
# hadolint ignore=DL3003,DL3008
RUN set -x \
&& apt-get update \
&& apt-get install -y --no-install-recommends wget ca-certificates \
&& wget https://github.com/Clozure/ccl/releases/download/v${CCL_VERSION}/ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& gunzip ccl-${CCL_VERSION}-linuxx86.tar.gz \
&& tar xf ccl-${CCL_VERSION}-linuxx86.tar \
&& (cd ccl && rm -rf .git && cp scripts/ccl64 /usr/local/bin/ccl ) \
&& rm ccl-${CCL_VERSION}-linuxx86.tar \
&& apt-get remove -y wget ca-certificates \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /
ENTRYPOINT ["ccl"]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment