forked from reanahub/reana-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
63 lines (55 loc) · 2.2 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
# This file is part of REANA.
# Copyright (C) 2024 CERN.
#
# REANA is free software; you can redistribute it and/or modify it
# under the terms of the MIT License; see LICENSE file for more details.
# Use Ubuntu LTS base image
FROM docker.io/library/ubuntu:20.04
# Use default answers in installation commands
ENV DEBIAN_FRONTEND=noninteractive
# Use distutils provided by the standard Python library instead of the vendored one in
# setuptools, so that editable installations are stored in the right directory.
# See https://github.com/pypa/setuptools/issues/3301
ENV SETUPTOOLS_USE_DISTUTILS=stdlib
# Add sources to `/code` and work there
WORKDIR /code
COPY . /code
# Install system dependencies and reana-client in one go
# hadolint ignore=DL3008,DL3013
RUN apt-get update -y && \
apt-get install --no-install-recommends -y \
gcc \
libpython3.8 \
python3-pip \
python3.8 \
python3.8-dev && \
# `pip3 install kubernetes` needed due to an old version of system pip3
pip3 install --no-cache-dir kubernetes '.[tests]' && \
apt-get remove -y \
gcc \
python3.8-dev && \
apt-get autoremove -y && \
apt-get clean && \
rm -rf /code /var/lib/apt/lists/*
# Run container as `reana` user with UID `1000`, which should match
# current host user in most situations
# hadolint ignore=DL3059
RUN adduser --uid 1000 reana --gid 0 && \
chown -R reana:root /home/reana
WORKDIR /home/reana
# Run reana-client upon entry
USER reana
ENTRYPOINT ["reana-client"]
# Set image labels
LABEL org.opencontainers.image.authors="[email protected]"
LABEL org.opencontainers.image.created="2024-03-14"
LABEL org.opencontainers.image.description="REANA reproducible analysis platform - command-line client"
LABEL org.opencontainers.image.documentation="https://reana-client.readthedocs.io/"
LABEL org.opencontainers.image.licenses="MIT"
LABEL org.opencontainers.image.source="https://github.com/reanahub/reana-client"
LABEL org.opencontainers.image.title="reana-client"
LABEL org.opencontainers.image.url="https://github.com/reanahub/reana-client"
LABEL org.opencontainers.image.vendor="reanahub"
# x-release-please-start-version
LABEL org.opencontainers.image.version="0.9.3"
# x-release-please-end