commit 0a5be1ae0ee9b15ddd7dd1e6cec1b6b9ebd48aa8 Author: Peter Morton Date: Wed Oct 12 18:24:16 2022 -0500 Initial commit diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..a0b4454 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,4 @@ +# syntax=docker/dockerfile:1 +FROM baseImage +LABEL site.mortons.author="" +LABEL site.mortons.version="1.0" \ No newline at end of file diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..f535e8b --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,27 @@ +pipeline { + agent any + + stages { + stage('Build') { + steps { + sh 'docker buildx bake --progress=plain' + } + } + + stage('Deploy') { + steps { + sh 'docker buildx bake --progress=plain --push' + } + } + } + + post { + always { + sh 'docker system prune --force --volumes' + cleanWs(cleanWhenNotBuilt: true, + deleteDirs: true, + disableDeferredWipeout: true, + notFailBuild: true) + } + } +} \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..2071b23 --- /dev/null +++ b/LICENSE @@ -0,0 +1,9 @@ +MIT License + +Copyright (c) + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..8786cb2 --- /dev/null +++ b/README.md @@ -0,0 +1,10 @@ +# eo-services + + created from template docker-image-template + +## Key Files + +* Jenkinsfile: Automation of build and deploy of docker image. +* Dockerfile: Docker Image specification. +* docker-bake.hcl: Docker build defintion file. + diff --git a/docker-bake.hcl b/docker-bake.hcl new file mode 100644 index 0000000..cb9f9d5 --- /dev/null +++ b/docker-bake.hcl @@ -0,0 +1,16 @@ +variable "TAG" { + default = "latest" +} +variable "REPO" { + default = "registry.mortons.site" +} + +group "default" { + targets = ["eo-services"] +} + +target "eo-services" { + dockerfile = "Dockerfile" + tags = ["${REPO}/eo-services:${TAG}"] + platforms = ["linux/amd64", "linux/arm64"] +} \ No newline at end of file