19 lines
813 B
Docker
19 lines
813 B
Docker
|
FROM alpine:latest
|
||
|
|
||
|
COPY init/entrypoint.sh /usr/local/bin
|
||
|
|
||
|
RUN chmod +x /usr/local/bin/entrypoint.sh && \
|
||
|
apk add --update --no-cache \
|
||
|
cups cups-filters cups-libs && \
|
||
|
sed -i 's/Listen localhost:631/Listen 0.0.0.0:631/' /etc/cups/cupsd.conf && \
|
||
|
sed -i 's/<Location \/>/<Location \/>\n Allow All/' /etc/cups/cupsd.conf && \
|
||
|
sed -i 's/<Location \/admin>/<Location \/admin>\n Allow All\n Require user @SYSTEM/' /etc/cups/cupsd.conf && \
|
||
|
sed -i 's/<Location \/admin\/conf>/<Location \/admin\/conf>\n Allow All/' /etc/cups/cupsd.conf && \
|
||
|
echo "ServerAlias *" >> /etc/cups/cupsd.conf && \
|
||
|
echo "DefaultEncryption Never" >> /etc/cups/cupsd.conf
|
||
|
|
||
|
VOLUME /etc/cups /var/log/cups /var/spool/cups /var/spool/cups-pdf /var/cache/cups
|
||
|
|
||
|
EXPOSE 631
|
||
|
|
||
|
CMD ["/usr/local/bin/entrypoint.sh"]
|