mirror of
https://github.com/asciinema/asciinema.git
synced 2025-12-15 19:28:00 +01:00
Refactor Dockerfile: consolidate instructions
This commit is contained in:
committed by
Marcin Kulik
parent
1330940de2
commit
e07e32d026
45
Dockerfile
45
Dockerfile
@@ -1,22 +1,37 @@
|
|||||||
FROM ubuntu:20.04
|
# syntax=docker/dockerfile:1.3
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y \
|
FROM docker.io/library/ubuntu:20.04
|
||||||
ca-certificates \
|
|
||||||
locales \
|
ENV DEBIAN_FRONTEND="noninteractive"
|
||||||
python3 \
|
|
||||||
python3-setuptools
|
RUN apt-get update \
|
||||||
RUN localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8
|
&& apt-get install -y \
|
||||||
RUN mkdir /usr/src/app
|
ca-certificates \
|
||||||
COPY setup.cfg /usr/src/app
|
locales \
|
||||||
COPY setup.py /usr/src/app
|
python3 \
|
||||||
COPY *.md /usr/src/app/
|
python3-setuptools \
|
||||||
|
&& localedef \
|
||||||
|
-i en_US \
|
||||||
|
-c \
|
||||||
|
-f UTF-8 \
|
||||||
|
-A /usr/share/locale/locale.alias en_US.UTF-8
|
||||||
|
|
||||||
|
COPY setup.cfg setup.py *.md /usr/src/app/
|
||||||
COPY doc/*.md /usr/src/app/doc/
|
COPY doc/*.md /usr/src/app/doc/
|
||||||
COPY man/asciinema.1 /usr/src/app/man/
|
COPY man/asciinema.1 /usr/src/app/man/
|
||||||
COPY asciinema /usr/src/app/asciinema
|
COPY asciinema/ /usr/src/app/asciinema/
|
||||||
|
|
||||||
WORKDIR /usr/src/app
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
RUN python3 setup.py install
|
RUN python3 setup.py install
|
||||||
ENV LANG en_US.utf8
|
|
||||||
ENV SHELL /bin/bash
|
ENV LANG="en_US.utf8"
|
||||||
ENV USER docker
|
ENV SHELL="/bin/bash"
|
||||||
|
ENV USER="docker"
|
||||||
|
|
||||||
WORKDIR /root
|
WORKDIR /root
|
||||||
|
|
||||||
ENTRYPOINT ["/usr/local/bin/asciinema"]
|
ENTRYPOINT ["/usr/local/bin/asciinema"]
|
||||||
|
CMD ["--help"]
|
||||||
|
|
||||||
|
# vim:ft=dockerfile
|
||||||
|
|||||||
Reference in New Issue
Block a user