add ServerAlias to cups conf
This commit is contained in:
parent
883eebe6fb
commit
a108170fa6
@ -23,15 +23,6 @@ build-amd64:
|
||||
- docker build --build-arg ARCH=amd64 -t ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64 .
|
||||
- docker push ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64
|
||||
|
||||
build-arm32v6:
|
||||
stage: build
|
||||
script:
|
||||
- wget https://github.com/multiarch/qemu-user-static/releases/download/${QEMU_VERSION}/qemu-arm-static -O qemu-arm-static
|
||||
- chmod 554 qemu-*-static
|
||||
- docker run --rm --privileged multiarch/qemu-user-static:register --reset
|
||||
- docker build --build-arg ARCH=arm32v6 -t ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6 .
|
||||
- docker push ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6
|
||||
|
||||
build-arm32v7:
|
||||
stage: build
|
||||
script:
|
||||
@ -56,18 +47,14 @@ release:
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64 ${CI_REGISTRY_IMAGE}:latest-amd64
|
||||
- docker push ${CI_REGISTRY_IMAGE}:latest-amd64
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6 ${CI_REGISTRY_IMAGE}:latest-arm32v6
|
||||
- docker push ${CI_REGISTRY_IMAGE}:latest-arm32v6
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7 ${CI_REGISTRY_IMAGE}:latest-arm32v7
|
||||
- docker push ${CI_REGISTRY_IMAGE}:latest-arm32v7
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8 ${CI_REGISTRY_IMAGE}:latest-arm64v8
|
||||
- docker push ${CI_REGISTRY_IMAGE}:latest-arm64v8
|
||||
- docker manifest create ${CI_REGISTRY_IMAGE}:latest ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64 ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6 ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7 ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8
|
||||
- docker manifest create ${CI_REGISTRY_IMAGE}:latest ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64 ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7 ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8
|
||||
- docker manifest annotate --os linux --arch amd64 ${CI_REGISTRY_IMAGE}:latest ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64
|
||||
- docker manifest annotate --os linux --arch arm --variant v6 ${CI_REGISTRY_IMAGE}:latest ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6
|
||||
- docker manifest annotate --os linux --arch arm --variant v7 ${CI_REGISTRY_IMAGE}:latest ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7
|
||||
- docker manifest annotate --os linux --arch arm64 --variant v8 ${CI_REGISTRY_IMAGE}:latest ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8
|
||||
- docker manifest push ${CI_REGISTRY_IMAGE}:latest
|
||||
@ -87,18 +74,14 @@ dockerhub:
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-amd64 ${DOCKERHUB_IMAGE}:latest-amd64
|
||||
- docker push ${DOCKERHUB_IMAGE}:latest-amd64
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v6 ${DOCKERHUB_IMAGE}:latest-arm32v6
|
||||
- docker push ${DOCKERHUB_IMAGE}:latest-arm32v6
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm32v7 ${DOCKERHUB_IMAGE}:latest-arm32v7
|
||||
- docker push ${DOCKERHUB_IMAGE}:latest-arm32v7
|
||||
- docker pull ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8
|
||||
- docker tag ${CI_REGISTRY_IMAGE}:${CI_PIPELINE_ID}-arm64v8 ${DOCKERHUB_IMAGE}:latest-arm64v8
|
||||
- docker push ${DOCKERHUB_IMAGE}:latest-arm64v8
|
||||
- docker manifest create ${DOCKERHUB_IMAGE}:latest ${DOCKERHUB_IMAGE}:latest-amd64 ${DOCKERHUB_IMAGE}:latest-arm32v6 ${DOCKERHUB_IMAGE}:latest-arm32v7 ${DOCKERHUB_IMAGE}:latest-arm64v8
|
||||
- docker manifest create ${DOCKERHUB_IMAGE}:latest ${DOCKERHUB_IMAGE}:latest-amd64 ${DOCKERHUB_IMAGE}:latest-arm32v7 ${DOCKERHUB_IMAGE}:latest-arm64v8
|
||||
- docker manifest annotate --os linux --arch amd64 ${DOCKERHUB_IMAGE}:latest ${DOCKERHUB_IMAGE}:latest-amd64
|
||||
- docker manifest annotate --os linux --arch arm --variant v6 ${DOCKERHUB_IMAGE}:latest ${DOCKERHUB_IMAGE}:latest-arm32v6
|
||||
- docker manifest annotate --os linux --arch arm --variant v7 ${DOCKERHUB_IMAGE}:latest ${DOCKERHUB_IMAGE}:latest-arm32v7
|
||||
- docker manifest annotate --os linux --arch arm64 --variant v8 ${DOCKERHUB_IMAGE}:latest ${DOCKERHUB_IMAGE}:latest-arm64v8
|
||||
- docker manifest push ${DOCKERHUB_IMAGE}:latest
|
||||
|
@ -1,6 +1,6 @@
|
||||
# Base image
|
||||
ARG ARCH=amd64
|
||||
FROM $ARCH/debian:buster-slim
|
||||
FROM $ARCH/debian:buster
|
||||
|
||||
# Prepare multi arch build
|
||||
COPY qemu-* /usr/bin/
|
||||
@ -37,10 +37,11 @@ RUN echo 'print ALL=(ALL:ALL) ALL' >> /etc/sudoers
|
||||
RUN /usr/sbin/cupsd \
|
||||
&& while [ ! -f /var/run/cups/cupsd.pid ]; do sleep 1; done \
|
||||
&& cupsctl --remote-admin --remote-any --share-printers \
|
||||
&& kill $(cat /var/run/cups/cupsd.pid)
|
||||
&& kill $(cat /var/run/cups/cupsd.pid) \
|
||||
&& echo "ServerAlias *" >> /etc/cups/cupsd.conf
|
||||
|
||||
# cleanup
|
||||
RUN rm -f /usr/bin/qemu-*-static /app/qemu-*-static
|
||||
RUN rm -f /usr/bin/qemu-*-static
|
||||
|
||||
# volumes
|
||||
VOLUME ["/etc/cups/printers.conf"]
|
||||
|
Loading…
x
Reference in New Issue
Block a user