Merge remote-tracking branch 'origin/release/v3.1.x' into release/v3.x
This commit is contained in:
commit
92a8da1c3c
7 changed files with 94 additions and 90 deletions
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
|
|
@ -37,4 +37,4 @@ jobs:
|
||||||
java-version: '21'
|
java-version: '21'
|
||||||
distribution: 'temurin'
|
distribution: 'temurin'
|
||||||
- name: Push with Gradle
|
- name: Push with Gradle
|
||||||
run: ./gradlew -Pwebsite.push.token=${{ secrets.WEBSITE_PUSH_TOKEN }} -Pdocker.registry=ghcr.io/${{ github.actor }} stage pushImages
|
run: ./gradlew -Pwebsite.push.token=${{ secrets.WEBSITE_PUSH_TOKEN }} -Pdocker.registry=ghcr.io/${{ github.actor }} stage publishImage
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ stages:
|
||||||
extends: .any-job
|
extends: .any-job
|
||||||
image: registry.mnl.de/org/jgrapes/jdk21-builder:v2
|
image: registry.mnl.de/org/jgrapes/jdk21-builder:v2
|
||||||
cache:
|
cache:
|
||||||
- key: dependencies
|
- key: dependencies-${CI_COMMIT_BRANCH}
|
||||||
policy: pull-push
|
policy: pull-push
|
||||||
paths:
|
paths:
|
||||||
- .gradle
|
- .gradle
|
||||||
|
|
@ -24,7 +24,7 @@ stages:
|
||||||
- "*/build"
|
- "*/build"
|
||||||
before_script:
|
before_script:
|
||||||
- echo -n $CI_REGISTRY_PASSWORD | podman login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY
|
- echo -n $CI_REGISTRY_PASSWORD | podman login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY
|
||||||
- git switch $CI_COMMIT_REF_NAME
|
- git switch $(git branch -r --sort="authordate" --contains $CI_COMMIT_SHA | head -1 | sed -e 's#[^/]*/##')
|
||||||
- git pull
|
- git pull
|
||||||
- git reset --hard $CI_COMMIT_SHA
|
- git reset --hard $CI_COMMIT_SHA
|
||||||
|
|
||||||
|
|
@ -37,8 +37,10 @@ build-jars:
|
||||||
publish-images:
|
publish-images:
|
||||||
stage: publish
|
stage: publish
|
||||||
extends: .gradle-job
|
extends: .gradle-job
|
||||||
|
dependencies:
|
||||||
|
- build-jars
|
||||||
script:
|
script:
|
||||||
- ./gradlew -Pdocker.registry=$CI_REGISTRY_IMAGE pushImage
|
- ./gradlew -Pdocker.registry=$CI_REGISTRY_IMAGE publishImage
|
||||||
|
|
||||||
.pages-job:
|
.pages-job:
|
||||||
extends: .any-job
|
extends: .any-job
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ spec:
|
||||||
containers:
|
containers:
|
||||||
- name: vm-operator
|
- name: vm-operator
|
||||||
image: >-
|
image: >-
|
||||||
ghcr.io/mnlipp/org.jdrupes.vmoperator.manager:3.1.1
|
ghcr.io/mnlipp/org.jdrupes.vmoperator.manager:3.1.2
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: config
|
- name: config
|
||||||
mountPath: /etc/opt/vmoperator
|
mountPath: /etc/opt/vmoperator
|
||||||
|
|
|
||||||
|
|
@ -46,6 +46,7 @@ application {
|
||||||
}
|
}
|
||||||
|
|
||||||
project.ext.gitBranch = grgit.branch.current.name.replace('/', '-')
|
project.ext.gitBranch = grgit.branch.current.name.replace('/', '-')
|
||||||
|
def registry = "${project.rootProject.properties['docker.registry']}"
|
||||||
|
|
||||||
task buildImage(type: Exec) {
|
task buildImage(type: Exec) {
|
||||||
dependsOn installDist
|
dependsOn installDist
|
||||||
|
|
@ -61,20 +62,23 @@ task pushImage(type: Exec) {
|
||||||
// Don't push without testing first
|
// Don't push without testing first
|
||||||
dependsOn test
|
dependsOn test
|
||||||
|
|
||||||
def registry = "${project.rootProject.properties['docker.registry']}"
|
|
||||||
commandLine 'podman', 'push', '--tls-verify=false', \
|
commandLine 'podman', 'push', '--tls-verify=false', \
|
||||||
"localhost/${project.name}:${project.gitBranch}", \
|
"${project.name}:${project.gitBranch}", \
|
||||||
"${registry}/${project.name}:${project.gitBranch}"
|
"${registry}/${project.name}:${project.gitBranch}"
|
||||||
|
}
|
||||||
|
|
||||||
if (!project.version.contains("SNAPSHOT")) {
|
task tagWithVersion(type: Exec) {
|
||||||
commandLine 'podman', 'tag', \
|
dependsOn pushImage
|
||||||
"${registry}/${project.name}:${project.gitBranch}",\
|
|
||||||
"${registry}/${project.name}:${project.version}"
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
}
|
|
||||||
|
commandLine 'podman', 'push', \
|
||||||
|
"${project.name}:${project.gitBranch}",\
|
||||||
|
"${registry}/${project.name}:${project.version}"
|
||||||
}
|
}
|
||||||
|
|
||||||
task tagAsLatest(type: Exec) {
|
task tagAsLatest(type: Exec) {
|
||||||
dependsOn pushImage
|
dependsOn tagWithVersion
|
||||||
|
|
||||||
enabled = !project.version.contains("SNAPSHOT")
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
&& !project.version.contains("alpha") \
|
&& !project.version.contains("alpha") \
|
||||||
|
|
@ -83,17 +87,22 @@ task tagAsLatest(type: Exec) {
|
||||||
&& project.rootProject.properties['docker.registry'] \
|
&& project.rootProject.properties['docker.registry'] \
|
||||||
== project.rootProject.properties['docker.testRegistry']
|
== project.rootProject.properties['docker.testRegistry']
|
||||||
|
|
||||||
def registry = "${project.rootProject.properties['docker.registry']}"
|
commandLine 'podman', 'push', \
|
||||||
commandLine 'podman', 'tag', \
|
"${project.name}:${project.gitBranch}",\
|
||||||
"${registry}/${project.name}:${project.version}",\
|
|
||||||
"${registry}/${project.name}:latest"
|
"${registry}/${project.name}:latest"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
task publishImage {
|
||||||
|
dependsOn pushImage
|
||||||
|
dependsOn tagWithVersion
|
||||||
|
dependsOn tagAsLatest
|
||||||
|
}
|
||||||
|
|
||||||
task pushForTest(type: Exec) {
|
task pushForTest(type: Exec) {
|
||||||
dependsOn buildImage
|
dependsOn buildImage
|
||||||
|
|
||||||
commandLine 'podman', 'push', '--tls-verify=false', \
|
commandLine 'podman', 'push', '--tls-verify=false', \
|
||||||
"localhost/${project.name}:${project.gitBranch}", \
|
"${project.name}:${project.gitBranch}", \
|
||||||
"${project.rootProject.properties['docker.testRegistry']}" \
|
"${project.rootProject.properties['docker.testRegistry']}" \
|
||||||
+ "/${project.name}:test"
|
+ "/${project.name}:test"
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -32,8 +32,9 @@ application {
|
||||||
}
|
}
|
||||||
|
|
||||||
project.ext.gitBranch = grgit.branch.current.name.replace('/', '-')
|
project.ext.gitBranch = grgit.branch.current.name.replace('/', '-')
|
||||||
|
def registry = "${project.rootProject.properties['docker.registry']}"
|
||||||
|
|
||||||
task buildArchImage(type: Exec) {
|
task buildImageArch(type: Exec) {
|
||||||
dependsOn installDist
|
dependsOn installDist
|
||||||
inputs.files 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.arch'
|
inputs.files 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.arch'
|
||||||
|
|
||||||
|
|
@ -42,23 +43,26 @@ task buildArchImage(type: Exec) {
|
||||||
'-f', 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.arch', '.'
|
'-f', 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.arch', '.'
|
||||||
}
|
}
|
||||||
|
|
||||||
task pushArchImage(type: Exec) {
|
task pushImageArch(type: Exec) {
|
||||||
dependsOn buildArchImage
|
dependsOn buildImageArch
|
||||||
|
|
||||||
def registry = "${project.rootProject.properties['docker.registry']}"
|
|
||||||
commandLine 'podman', 'push', '--tls-verify=false', \
|
commandLine 'podman', 'push', '--tls-verify=false', \
|
||||||
"localhost/${project.name}-arch:${project.gitBranch}", \
|
"${project.name}-arch:${project.gitBranch}", \
|
||||||
"${registry}/${project.name}-arch:${project.gitBranch}"
|
"${registry}/${project.name}-arch:${project.gitBranch}"
|
||||||
|
}
|
||||||
|
|
||||||
if (!project.version.contains("SNAPSHOT")) {
|
task tagWithVersionArch(type: Exec) {
|
||||||
commandLine 'podman', 'tag', \
|
dependsOn pushImageArch
|
||||||
"${registry}/${project.name}-arch:${project.gitBranch}",\
|
|
||||||
"${registry}/${project.name}-arch:${project.version}"
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
}
|
|
||||||
|
commandLine 'podman', 'push', \
|
||||||
|
"${project.name}-arch:${project.gitBranch}",\
|
||||||
|
"${registry}/${project.name}-arch:${project.version}"
|
||||||
}
|
}
|
||||||
|
|
||||||
task tagAsLatestArch(type: Exec) {
|
task tagAsLatestArch(type: Exec) {
|
||||||
dependsOn pushArchImage
|
dependsOn tagWithVersionArch
|
||||||
|
|
||||||
enabled = !project.version.contains("SNAPSHOT")
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
&& !project.version.contains("alpha") \
|
&& !project.version.contains("alpha") \
|
||||||
|
|
@ -67,13 +71,12 @@ task tagAsLatestArch(type: Exec) {
|
||||||
&& project.rootProject.properties['docker.registry'] \
|
&& project.rootProject.properties['docker.registry'] \
|
||||||
== project.rootProject.properties['docker.testRegistry']
|
== project.rootProject.properties['docker.testRegistry']
|
||||||
|
|
||||||
def registry = "${project.rootProject.properties['docker.registry']}"
|
commandLine 'podman', 'push', \
|
||||||
commandLine 'podman', 'tag', \
|
"${project.name}-arch:${project.gitBranch}",\
|
||||||
"${registry}/${project.name}-arch:${project.version}",\
|
|
||||||
"${registry}/${project.name}-arch:latest"
|
"${registry}/${project.name}-arch:latest"
|
||||||
}
|
}
|
||||||
|
|
||||||
task buildAlpineImage(type: Exec) {
|
task buildImageAlpine(type: Exec) {
|
||||||
dependsOn installDist
|
dependsOn installDist
|
||||||
inputs.files 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.alpine'
|
inputs.files 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.alpine'
|
||||||
|
|
||||||
|
|
@ -82,23 +85,26 @@ task buildAlpineImage(type: Exec) {
|
||||||
'-f', 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.alpine', '.'
|
'-f', 'src/org/jdrupes/vmoperator/runner/qemu/Containerfile.alpine', '.'
|
||||||
}
|
}
|
||||||
|
|
||||||
task pushAlpineImage(type: Exec) {
|
task pushImageAlpine(type: Exec) {
|
||||||
dependsOn buildAlpineImage
|
dependsOn buildImageAlpine
|
||||||
|
|
||||||
def registry = "${project.rootProject.properties['docker.registry']}"
|
|
||||||
commandLine 'podman', 'push', '--tls-verify=false', \
|
commandLine 'podman', 'push', '--tls-verify=false', \
|
||||||
"localhost/${project.name}-alpine:${project.gitBranch}", \
|
"localhost/${project.name}-alpine:${project.gitBranch}", \
|
||||||
"${registry}/${project.name}-alpine:${project.gitBranch}"
|
"${registry}/${project.name}-alpine:${project.gitBranch}"
|
||||||
|
}
|
||||||
|
|
||||||
if (!project.version.contains("SNAPSHOT")) {
|
task tagWithVersionAlpine(type: Exec) {
|
||||||
commandLine 'podman', 'tag', \
|
dependsOn pushImageAlpine
|
||||||
"${registry}/${project.name}-alpine:${project.gitBranch}",\
|
|
||||||
"${registry}/${project.name}-alpine:${project.version}"
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
}
|
|
||||||
|
commandLine 'podman', 'push', \
|
||||||
|
"${project.name}-alpine:${project.gitBranch}",\
|
||||||
|
"${registry}/${project.name}-alpine:${project.version}"
|
||||||
}
|
}
|
||||||
|
|
||||||
task tagAsLatestAlpine(type: Exec) {
|
task tagAsLatestAlpine(type: Exec) {
|
||||||
dependsOn pushAlpineImage
|
dependsOn tagWithVersionAlpine
|
||||||
|
|
||||||
enabled = !project.version.contains("SNAPSHOT")
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
&& !project.version.contains("alpha") \
|
&& !project.version.contains("alpha") \
|
||||||
|
|
@ -107,19 +113,16 @@ task tagAsLatestAlpine(type: Exec) {
|
||||||
&& project.rootProject.properties['docker.registry'] \
|
&& project.rootProject.properties['docker.registry'] \
|
||||||
== project.rootProject.properties['docker.testRegistry']
|
== project.rootProject.properties['docker.testRegistry']
|
||||||
|
|
||||||
def registry = "${project.rootProject.properties['docker.registry']}"
|
commandLine 'podman', 'push', \
|
||||||
commandLine 'podman', 'tag', \
|
"${project.name}-alpine:${project.gitBranch}",\
|
||||||
"${registry}/${project.name}-alpine:${project.version}",\
|
|
||||||
"${registry}/${project.name}-alpine:latest"
|
"${registry}/${project.name}-alpine:latest"
|
||||||
}
|
}
|
||||||
|
|
||||||
task pushImage {
|
task publishImage {
|
||||||
dependsOn pushArchImage
|
dependsOn pushImageArch
|
||||||
dependsOn pushAlpineImage
|
dependsOn tagWithVersionArch
|
||||||
}
|
|
||||||
|
|
||||||
task tagAsLatest {
|
|
||||||
dependsOn tagAsLatestArch
|
dependsOn tagAsLatestArch
|
||||||
|
dependsOn pushImageAlpine
|
||||||
|
dependsOn tagWithVersionAlpine
|
||||||
dependsOn tagAsLatestAlpine
|
dependsOn tagAsLatestAlpine
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,44 +5,36 @@ plugins {
|
||||||
dependencies {
|
dependencies {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
project.ext.gitBranch = grgit.branch.current.name.replace('/', '-')
|
||||||
|
def registry = "${project.rootProject.properties['docker.registry']}"
|
||||||
|
|
||||||
task buildImage(type: Exec) {
|
task buildImage(type: Exec) {
|
||||||
inputs.files 'Containerfile'
|
inputs.files 'Containerfile'
|
||||||
|
|
||||||
commandLine 'podman', 'build', '--pull',
|
commandLine 'podman', 'build', '--pull',
|
||||||
'-t', "${project.name}:${project.version}",\
|
'-t', "${project.name}:${project.gitBranch}",\
|
||||||
'-f', 'Containerfile', '.'
|
'-f', 'Containerfile', '.'
|
||||||
}
|
}
|
||||||
|
|
||||||
task tagLatestImage(type: Exec) {
|
|
||||||
dependsOn buildImage
|
|
||||||
|
|
||||||
enabled = !project.version.contains("SNAPSHOT")
|
|
||||||
&& !project.version.contains("alpha") \
|
|
||||||
&& !project.version.contains("beta") \
|
|
||||||
|| project.rootProject.properties['docker.testRegistry'] \
|
|
||||||
&& project.rootProject.properties['docker.registry'] \
|
|
||||||
== project.rootProject.properties['docker.testRegistry']
|
|
||||||
|
|
||||||
commandLine 'podman', 'tag', "${project.name}:${project.version}",\
|
|
||||||
"${project.name}:latest"
|
|
||||||
}
|
|
||||||
|
|
||||||
task buildLatestImage {
|
|
||||||
dependsOn buildImage
|
|
||||||
dependsOn tagLatestImage
|
|
||||||
}
|
|
||||||
|
|
||||||
task pushImage(type: Exec) {
|
task pushImage(type: Exec) {
|
||||||
dependsOn buildImage
|
dependsOn buildImage
|
||||||
|
|
||||||
commandLine 'podman', 'push', '--tls-verify=false', \
|
commandLine 'podman', 'push', '--tls-verify=false', \
|
||||||
"localhost/${project.name}:${project.version}", \
|
"${project.name}:${project.gitBranch}", \
|
||||||
"${project.rootProject.properties['docker.registry']}" \
|
"${registry}/${project.name}:${project.gitBranch}"
|
||||||
+ "/${project.name}:${project.version}"
|
}
|
||||||
|
task tagWithVersion(type: Exec) {
|
||||||
|
dependsOn pushImage
|
||||||
|
|
||||||
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
|
|
||||||
|
commandLine 'podman', 'push', \
|
||||||
|
"${project.name}:${project.gitBranch}",\
|
||||||
|
"${registry}/${project.name}:${project.version}"
|
||||||
}
|
}
|
||||||
|
|
||||||
task pushLatestImage(type: Exec) {
|
task tagAsLatest(type: Exec) {
|
||||||
dependsOn buildLatestImage
|
dependsOn tagWithVersion
|
||||||
|
|
||||||
enabled = !project.version.contains("SNAPSHOT")
|
enabled = !project.version.contains("SNAPSHOT")
|
||||||
&& !project.version.contains("alpha") \
|
&& !project.version.contains("alpha") \
|
||||||
|
|
@ -51,18 +43,16 @@ task pushLatestImage(type: Exec) {
|
||||||
&& project.rootProject.properties['docker.registry'] \
|
&& project.rootProject.properties['docker.registry'] \
|
||||||
== project.rootProject.properties['docker.testRegistry']
|
== project.rootProject.properties['docker.testRegistry']
|
||||||
|
|
||||||
commandLine 'podman', 'push', '--tls-verify=false', \
|
commandLine 'podman', 'push', \
|
||||||
"localhost/${project.name}:${project.version}", \
|
"${project.name}:${project.gitBranch}",\
|
||||||
"${project.rootProject.properties['docker.registry']}" \
|
"${registry}/${project.name}:latest"
|
||||||
+ "/${project.name}:latest"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
task pushImages {
|
task publishImage {
|
||||||
// Don't push without testing first
|
|
||||||
dependsOn pushImage
|
dependsOn pushImage
|
||||||
dependsOn pushLatestImage
|
dependsOn tagWithVersion
|
||||||
|
dependsOn tagAsLatest
|
||||||
}
|
}
|
||||||
|
|
||||||
test {
|
test {
|
||||||
enabled = project.hasProperty("k8s.testCluster")
|
enabled = project.hasProperty("k8s.testCluster")
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,15 +11,15 @@ based VMs in Kubernetes pods.
|
||||||
|
|
||||||
The image used for the VM pods combines Qemu and a control program
|
The image used for the VM pods combines Qemu and a control program
|
||||||
for starting and managing the Qemu process. This application is called
|
for starting and managing the Qemu process. This application is called
|
||||||
"[the runner](runner.md)".
|
"[the runner](runner.html)".
|
||||||
|
|
||||||
While you can deploy a runner manually (or with the help of some
|
While you can deploy a runner manually (or with the help of some
|
||||||
helm templates), the preferred way is to deploy "[the manager](manager.md)"
|
helm templates), the preferred way is to deploy "[the manager](manager.html)"
|
||||||
application which acts as a Kubernetes operator for runners
|
application which acts as a Kubernetes operator for runners
|
||||||
and thus the VMs.
|
and thus the VMs.
|
||||||
|
|
||||||
If you just want to try out things, you can skip the remainder of this
|
If you just want to try out things, you can skip the remainder of this
|
||||||
page and proceed to "[the manager](manager.md)".
|
page and proceed to "[the manager](manager.html)".
|
||||||
|
|
||||||
## Motivation
|
## Motivation
|
||||||
The project was triggered by a remark in the discussion about RedHat
|
The project was triggered by a remark in the discussion about RedHat
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue