-
Notifications
You must be signed in to change notification settings - Fork 30
/
Dockerfile
28 lines (21 loc) · 859 Bytes
/
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
FROM docker.io/rockylinux/rockylinux:8
LABEL maintainer="Mario Trangoni <[email protected]>"
LABEL org.opencontainers.image.source="https://github.com/mjtrangoni/flexlm_exporter"
# Install dependencies and clean cache
RUN rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-rockyofficial && \
dnf -y update && \
dnf -y install bash-completion redhat-lsb-core strace && \
dnf -y clean all && \
rm -f /etc/pki/tls/private/postfix.key
COPY flexlm_exporter /bin/flexlm_exporter
# Add exporter user and group
RUN groupadd -g 30001 exporter && \
useradd --no-log-init -m -d /home/exporter -u 30001 -g 30001 exporter
EXPOSE 9319
USER exporter
WORKDIR /home/exporter
RUN mkdir -p /home/exporter/config &&\
chown -R 30001:30001 /home/exporter/config
# Default home dir
ENV HOME=/home/exporter
ENTRYPOINT [ "/bin/flexlm_exporter" ]