forked from gpdm/nut
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
23 lines (17 loc) · 985 Bytes
/
Copy pathDockerfile
File metadata and controls
23 lines (17 loc) · 985 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
FROM alpine:3.24
# renovate: datasource=repology depName=alpine_3_23/nut versioning=loose
ENV NUT_VERSION="2.8.3-r4"
RUN apk add --no-cache nut="${NUT_VERSION}" shadow tini && \
[ -d /etc/nut ] && find /etc/nut/ -type f -exec mv {} {}.sample \; || false && \
mkdir -p /var/run/nut && \
chown nut:nut /var/run/nut && \
chmod 700 /var/run/nut && \
# fix some missing links to .so files, which are required to run 'nut-scanner' utility
find /usr/lib/ -type f -name 'libusb*' -exec ln -sf {} /usr/lib/libusb-1.0.so \; || false && \
find /usr/lib/ -type f -name 'libnetsnmp*' -exec ln -sf {} /usr/lib/libnetsnmp.so \; || false && \
find /usr/lib/ -type f -name 'libupsclient*' -exec ln -sf {} /usr/lib/libupsclient.so \; || false && \
find /usr/lib/ -type f -name 'libneon*' -exec ln -sf {} /usr/lib/libneon.so \; || false
COPY entrypoint.sh /entrypoint.sh
RUN chmod 755 /entrypoint.sh
ENTRYPOINT ["/sbin/tini", "--", "/entrypoint.sh"]
EXPOSE 3493