Dockerfile

Thu, 23 Mar 2023 15:12:30 +0000

author
Matthew Wild <mwild1@gmail.com>
date
Thu, 23 Mar 2023 15:12:30 +0000
changeset 174
662bd8c5ae28
parent 141
7b774278ca84
child 179
8a9bf558aead
permissions
-rw-r--r--

Serialize XML in a consistent order by default

This overrides all XML serialization to emit attributes in an ordered form, so
the XML will match across multiple runs. This can be useful for comparing
different runs, or even two stanzas printed in the same run (e.g. if there is
a mismatch).

FROM ubuntu:xenial

MAINTAINER Matthew Wild <mwild1@gmail.com>

RUN apt-get update \
    && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
        lua5.2 \
        lua-cjson \
        lua-expat \
	lua-filesystem \
        lua-sec \
        lua-socket \
        make \
    && rm -rf /var/lib/apt/lists/*

RUN ln -s /usr/bin/lua5.2 /usr/local/bin/lua

RUN mkdir -p /tmp/build

ADD . /tmp/build

WORKDIR /tmp/build

RUN ./configure && make && install build/scansion /usr/local/bin/scansion && rm -rf /tmp/build

ADD verse.lua /usr/local/share/lua/5.2/verse.lua

ADD misc/docker-entrypoint.sh /entrypoint.sh

RUN chmod a=rx /entrypoint.sh

ENTRYPOINT ["/entrypoint.sh"]

USER nobody

ADD scripts /scripts

VOLUME ["/scripts"]

WORKDIR /scripts

CMD ["-d", "/scripts"]

mercurial