mirror of
https://github.com/nikdoof/cups-avahi-airprint.git
synced 2025-12-11 15:52:24 +00:00
Merge pull request #10 from chuckcharlie/buildtest
ARM and automated build support
This commit is contained in:
@@ -2,6 +2,10 @@
|
||||
|
||||
Fork from [quadportnick/docker-cups-airprint](https://github.com/quadportnick/docker-cups-airprint)
|
||||
|
||||
### Now supports ARM64 and AMD64!
|
||||
Use the *latest* tag to auto choose the right architecture.
|
||||
Please test and let me know. I don't have anything at home to test ARM with.
|
||||
|
||||
This Alpine-based Docker image runs a CUPS instance that is meant as an AirPrint relay for printers that are already on the network but not AirPrint capable. The other images out there never seemed to work right. I forked the original to use Alpine instead of Ubuntu and work on more host OS's.
|
||||
|
||||
## Configuration
|
||||
|
||||
31
buildspec-manifest.yml
Normal file
31
buildspec-manifest.yml
Normal file
@@ -0,0 +1,31 @@
|
||||
version: 0.2
|
||||
#Buildspec file for AWS Codebuild
|
||||
#Generates multi-arch manifest
|
||||
|
||||
env:
|
||||
secrets-manager:
|
||||
DOCKERHUB_PASS: "/dockerhub/credentials:password"
|
||||
DOCKERHUB_USERNAME: "/dockerhub/credentials:username"
|
||||
phases:
|
||||
install:
|
||||
commands:
|
||||
- yum update -y
|
||||
pre_build:
|
||||
commands:
|
||||
- echo Logging in to DOCKER...
|
||||
- docker login --username $DOCKERHUB_USERNAME --password $DOCKERHUB_PASS
|
||||
build:
|
||||
commands:
|
||||
- echo Build started on `date`
|
||||
- echo Building the Docker manifest...
|
||||
- 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
|
||||
|
||||
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
|
||||
29
buildspec.yml
Normal file
29
buildspec.yml
Normal file
@@ -0,0 +1,29 @@
|
||||
version: 0.2
|
||||
#Generic buildspec file for AWS Codebuild
|
||||
#Works for both ARM and AMD builds
|
||||
env:
|
||||
secrets-manager:
|
||||
DOCKERHUB_PASS: "/dockerhub/credentials:password"
|
||||
DOCKERHUB_USERNAME: "/dockerhub/credentials:username"
|
||||
phases:
|
||||
install:
|
||||
commands:
|
||||
- yum update -y
|
||||
pre_build:
|
||||
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
|
||||
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
|
||||
Reference in New Issue
Block a user