From a9a9b271fe6ea6c856159033e2328a3098bf1cc3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ingy=20d=C3=B6t=20Net?= Date: Sun, 7 Jan 2018 13:23:08 -0800 Subject: Docker test file changes (added alpine testing) Also reworked all the dockerfiles to be cleaner and consistent: * Fixed some indentation * Removed vim dependencies * Collapsed RUN steps for less build layers * Renamed dockerfiles/ to shorter and more adaptable docker/ --- docker/README.mkd | 17 +++++++++++++++++ docker/alpine-3.7 | 26 ++++++++++++++++++++++++++ docker/fedora-25 | 26 ++++++++++++++++++++++++++ docker/ubuntu-14.04 | 29 +++++++++++++++++++++++++++++ docker/ubuntu-16.04 | 24 ++++++++++++++++++++++++ 5 files changed, 122 insertions(+) create mode 100644 docker/README.mkd create mode 100644 docker/alpine-3.7 create mode 100644 docker/fedora-25 create mode 100644 docker/ubuntu-14.04 create mode 100644 docker/ubuntu-16.04 (limited to 'docker') diff --git a/docker/README.mkd b/docker/README.mkd new file mode 100644 index 0000000..71c13e1 --- /dev/null +++ b/docker/README.mkd @@ -0,0 +1,17 @@ +# LibYAML Dockerfiles + +This directory is a collection of dockerfiles that can be used when developing +and testing LibYAML. + +The current list is supports: + +- Ubuntu 16.04 +- Ubuntu 14.04 + +## Example Usage + +```bash +$ docker pull ubuntu +$ docker build -t libyaml-ubuntu:16.04 -f dockerfiles/ubuntu-16.04 . +$ docker run -it libyaml-ubuntu:16.04 make test +``` diff --git a/docker/alpine-3.7 b/docker/alpine-3.7 new file mode 100644 index 0000000..ac2d625 --- /dev/null +++ b/docker/alpine-3.7 @@ -0,0 +1,26 @@ +# vim: ft=dockerfile +FROM alpine:3.7 +MAINTAINER Ingy döt Net + +RUN apk update && \ + apk add --no-cache \ + autoconf \ + automake \ + build-base \ + cmake \ + git \ + libtool \ + perl-dev && \ + mkdir /libyaml + +COPY . /libyaml/ +WORKDIR /libyaml + +ENV LD_LIBRARY_PATH=/libyaml/src/.libs + +RUN ./bootstrap && \ + ./configure && \ + make && \ + make install + +CMD ["bash"] diff --git a/docker/fedora-25 b/docker/fedora-25 new file mode 100644 index 0000000..36e58ab --- /dev/null +++ b/docker/fedora-25 @@ -0,0 +1,26 @@ +# vim: ft=dockerfile +FROM fedora:25 +MAINTAINER Ian Cordasco + +# NOTE(sigmavirus24): We need "perl-core" here for the "prove" binary +# required by the test-all Makefile target +RUN dnf install -y \ + automake \ + gcc \ + git \ + make \ + libtool \ + perl-core && \ + mkdir /libyaml + +COPY . /libyaml/ +WORKDIR /libyaml + +ENV LD_LIBRARY_PATH=/libyaml/src/.libs + +RUN ./bootstrap && \ + ./configure && \ + make && \ + make install + +CMD ["bash"] diff --git a/docker/ubuntu-14.04 b/docker/ubuntu-14.04 new file mode 100644 index 0000000..6a2b134 --- /dev/null +++ b/docker/ubuntu-14.04 @@ -0,0 +1,29 @@ +# vim: ft=dockerfile +FROM ubuntu:14.04 +MAINTAINER Ian Cordasco + +RUN apt-get update && \ + apt-get install -y \ + software-properties-common \ + python-software-properties && \ + add-apt-repository ppa:git-core/ppa && \ + apt-get update && \ + apt-get install -y \ + autoconf \ + build-essential \ + git \ + libtool && \ + rm -rf /var/lib/apt/lists/* && \ + mkdir /libyaml + +COPY . /libyaml/ +WORKDIR /libyaml + +ENV LD_LIBRARY_PATH=/libyaml/src/.libs + +RUN ./bootstrap && \ + ./configure && \ + make && \ + make install + +CMD ["bash"] diff --git a/docker/ubuntu-16.04 b/docker/ubuntu-16.04 new file mode 100644 index 0000000..87b7afd --- /dev/null +++ b/docker/ubuntu-16.04 @@ -0,0 +1,24 @@ +# vim: ft=dockerfile +FROM ubuntu:16.04 +MAINTAINER Ian Cordasco + +RUN apt-get update && \ + apt-get install -y \ + autoconf \ + build-essential \ + git \ + libtool && \ + rm -rf /var/lib/apt/lists/* && \ + mkdir /libyaml + +COPY . /libyaml/ +WORKDIR /libyaml + +ENV LD_LIBRARY_PATH=/libyaml/src/.libs + +RUN ./bootstrap && \ + ./configure && \ + make && \ + make install + +CMD ["bash"] -- cgit v1.2.1