mirror of
https://github.com/nikdoof/cups-avahi-airprint.git
synced 2025-12-11 15:52:24 +00:00
Merge pull request #12 from chuckcharlie/buildtest
New cupsd.conf location and tagging logic
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
FROM alpine:latest
|
||||
FROM alpine:3.16
|
||||
|
||||
# Install the packages we need. Avahi will be included
|
||||
RUN echo -e "http://nl.alpinelinux.org/alpine/edge/testing\nhttp://dl-cdn.alpinelinux.org/alpine/edge/main" >> /etc/apk/repositories &&\
|
||||
|
||||
@@ -17,15 +17,19 @@ phases:
|
||||
build:
|
||||
commands:
|
||||
- echo Build started on `date`
|
||||
- echo Building the Docker manifest...
|
||||
- echo Building the Docker manifest...
|
||||
- VERSION=$(cat version.txt)
|
||||
- export DOCKER_CLI_EXPERIMENTAL=enabled
|
||||
- docker manifest create $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:latest-arm64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:latest-amd64
|
||||
- docker manifest annotate --arch arm64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:latest-arm64
|
||||
- docker manifest annotate --arch amd64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:latest-amd64
|
||||
- docker manifest create $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-arm64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-amd64
|
||||
- docker manifest annotate --arch arm64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-arm64
|
||||
- docker manifest annotate --arch amd64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-amd64
|
||||
- docker manifest create $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:latest $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-arm64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-amd64
|
||||
- docker manifest annotate --arch arm64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-arm64
|
||||
- docker manifest annotate --arch amd64 $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-amd64
|
||||
|
||||
post_build:
|
||||
commands:
|
||||
- echo Build completed on `date`
|
||||
- echo Pushing the Docker image...
|
||||
- docker manifest push $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME
|
||||
- docker manifest inspect $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME
|
||||
- docker manifest push $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION
|
||||
- docker manifest push $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:latest
|
||||
|
||||
@@ -13,17 +13,14 @@ phases:
|
||||
commands:
|
||||
- echo Logging in to DOCKER...
|
||||
- docker login --username $DOCKERHUB_USERNAME --password $DOCKERHUB_PASS
|
||||
#- $(aws ecr get-login --no-include-email --region $AWS_DEFAULT_REGION)
|
||||
build:
|
||||
commands:
|
||||
- echo Build started on `date`
|
||||
- echo Building the Docker image...
|
||||
- docker build -t $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$IMAGE_TAG .
|
||||
- docker tag $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$IMAGE_TAG $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$IMAGE_TAG
|
||||
#- docker tag $IMAGE_REPO_NAME:$IMAGE_TAG $AWS_ACCOUNT_ID.dkr.ecr.$AWS_DEFAULT_REGION.amazonaws.com/$IMAGE_REPO_NAME:$IMAGE_TAG
|
||||
- echo Building the Docker image...
|
||||
- VERSION=$(cat version.txt)
|
||||
- docker build -t $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$VERSION-$ARCH -t $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$IMAGE_TAG-$ARCH .
|
||||
post_build:
|
||||
commands:
|
||||
- echo Build completed on `date`
|
||||
- echo Pushing the Docker image...
|
||||
- docker push $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME:$IMAGE_TAG
|
||||
#- docker push $AWS_ACCOUNT_ID.dkr.ecr.$AWS_DEFAULT_REGION.amazonaws.com/$IMAGE_REPO_NAME:$IMAGE_TAG
|
||||
- docker push $DOCKERHUB_USERNAME/$IMAGE_REPO_NAME --all-tags
|
||||
|
||||
@@ -30,6 +30,10 @@ if [ `ls -l /config/printers.conf 2>/dev/null | wc -l` -eq 0 ]; then
|
||||
fi
|
||||
cp /config/printers.conf /etc/cups/printers.conf
|
||||
|
||||
if [ `ls -l /config/cupsd.conf 2>/dev/null | wc -l` -eq 0 ]; then
|
||||
cp /etc/cups/cupsd.conf /config/cupsd.conf
|
||||
fi
|
||||
|
||||
/usr/sbin/avahi-daemon --daemonize
|
||||
/root/printer-update.sh &
|
||||
exec /usr/sbin/cupsd -f
|
||||
exec /usr/sbin/cupsd -f -c /config/cupsd.conf
|
||||
|
||||
1
version.txt
Normal file
1
version.txt
Normal file
@@ -0,0 +1 @@
|
||||
1.1.0
|
||||
Reference in New Issue
Block a user