Files
HAddons/samba/Dockerfile
ai-dev 8e559fa82c test
2025-10-11 11:17:26 +02:00

36 lines
825 B
Docker

ARG BUILD_FROM
FROM $BUILD_FROM
# Add env
ENV LANG C.UTF-8
# Set S6 wait time
ENV S6_CMD_WAIT_FOR_SERVICES=1 \
S6_CMD_WAIT_FOR_SERVICES_MAXTIME=0 \
S6_SERVICES_GRACETIME=0
USER root
# Setup base
RUN \
apk add --no-cache samba \
&& mkdir -p /var/lib/samba \
&& touch \
/etc/samba/lmhosts \
/var/lib/samba/account_policy.tdb \
/var/lib/samba/registry.tdb \
/var/lib/samba/winbindd_idmap.tdb
# Copy data
COPY rootfs /
# Modules
ARG MODULES="00-local_mounts.sh"
# Automatic modules download
ADD "https://raw.githubusercontent.com/alexbelgium/hassio-addons/master/.templates/ha_automodules.sh" "/ha_automodules.sh"
RUN chmod 744 /ha_automodules.sh && /ha_automodules.sh "$MODULES" && rm /ha_automodules.sh
HEALTHCHECK \
CMD smbclient -L '\\localhost' -U '%' -m SMB3