Skip to content

Commit f5eac44

Browse files
author
Patrick Schwager
committed
switch helm plugin
1 parent 4789ff0 commit f5eac44

File tree

4 files changed

+15
-37
lines changed

4 files changed

+15
-37
lines changed

build.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ plugins {
1212
id("io.spring.dependency-management")
1313
id("dev.yumi.gradle.licenser")
1414

15-
id("com.citi.helm")
16-
id("com.citi.helm-publish")
15+
id("io.github.build-extensions-oss.helm")
16+
id("io.github.build-extensions-oss.helm-publish")
1717
id("net.researchgate.release")
1818
id("com.vanniktech.maven.publish")
1919
kotlin("jvm")

lmos-runtime-graphql-service/build.gradle.kts

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ import org.springframework.boot.gradle.tasks.bundling.BootBuildImage
99
plugins {
1010
id("org.springframework.boot")
1111
id("io.spring.dependency-management")
12-
id("com.citi.helm")
13-
id("com.citi.helm-publish")
12+
id("io.github.build-extensions-oss.helm")
13+
id("io.github.build-extensions-oss.helm-publish")
1414
}
1515

1616
dependencies {
@@ -50,27 +50,16 @@ tasks.named<BootBuildImage>("bootBuildImage") {
5050

5151
helm {
5252
charts {
53-
create("main") {
54-
chartName.set("${rootProject.name}-graphql-chart")
55-
chartVersion.set("${project.version}")
53+
create("${rootProject.name}-graphql-chart") {
5654
sourceDir.set(file("src/main/helm"))
5755
}
5856
}
5957
}
6058

61-
tasks.register("replaceChartVersion") {
62-
doLast {
63-
val chartFile = file("src/main/helm/Chart.yaml")
64-
val content = chartFile.readText()
65-
val updatedContent = content.replace("\${chartVersion}", "${project.version}")
66-
chartFile.writeText(updatedContent)
67-
}
68-
}
69-
7059
tasks.register("helmPush") {
7160
description = "Push Helm chart to OCI registry"
7261
group = "publishing"
73-
dependsOn(tasks.named("helmPackageMainChart"))
62+
dependsOn(tasks.named("helmPackageLmosRuntimeGraphqlChartChart"))
7463

7564
doLast {
7665
group = "publishing"
@@ -89,7 +78,7 @@ tasks.register("helmPush") {
8978
helm.execHelm("push") {
9079
args(
9180
tasks
92-
.named("helmPackageMainChart")
81+
.named("helmPackageLmosRuntimeGraphqlChartChart")
9382
.get()
9483
.outputs.files.singleFile
9584
.toString(),

lmos-runtime-service/build.gradle.kts

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ plugins {
1010
id("org.jetbrains.kotlin.plugin.spring")
1111
id("org.springframework.boot")
1212
id("io.spring.dependency-management")
13-
id("com.citi.helm")
14-
id("com.citi.helm-publish")
13+
id("io.github.build-extensions-oss.helm")
14+
id("io.github.build-extensions-oss.helm-publish")
1515
}
1616

1717
dependencies {
@@ -51,27 +51,16 @@ tasks.named<BootBuildImage>("bootBuildImage") {
5151

5252
helm {
5353
charts {
54-
create("main") {
55-
chartName.set("${rootProject.name}-chart")
56-
chartVersion.set("${project.version}")
54+
create("${rootProject.name}-chart") {
5755
sourceDir.set(file("src/main/helm"))
5856
}
5957
}
6058
}
6159

62-
tasks.register("replaceChartVersion") {
63-
doLast {
64-
val chartFile = file("src/main/helm/Chart.yaml")
65-
val content = chartFile.readText()
66-
val updatedContent = content.replace("\${chartVersion}", "${project.version}")
67-
chartFile.writeText(updatedContent)
68-
}
69-
}
70-
7160
tasks.register("helmPush") {
7261
description = "Push Helm chart to OCI registry"
7362
group = "publishing"
74-
dependsOn(tasks.named("helmPackageMainChart"))
63+
dependsOn(tasks.named("helmPackageLmosRuntimeChartChart"))
7564

7665
doLast {
7766
group = "publishing"
@@ -90,7 +79,7 @@ tasks.register("helmPush") {
9079
helm.execHelm("push") {
9180
args(
9281
tasks
93-
.named("helmPackageMainChart")
82+
.named("helmPackageLmosRuntimeChartChart")
9483
.get()
9584
.outputs.files.singleFile
9685
.toString(),

settings.gradle.kts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ include("lmos-runtime-bom")
1414

1515
pluginManagement {
1616
val kotlinVersion = "2.3.10"
17-
val helmVersion = "2.2.0"
17+
val helmVersion = "3.1.1"
1818

1919
repositories {
2020
gradlePluginPortal()
@@ -26,8 +26,8 @@ pluginManagement {
2626
id("org.jlleitschuh.gradle.ktlint") version "14.0.1"
2727
id("io.spring.dependency-management") version "1.1.7"
2828
id("dev.yumi.gradle.licenser") version "2.2.2"
29-
id("com.citi.helm") version helmVersion
30-
id("com.citi.helm-publish") version helmVersion
29+
id("io.github.build-extensions-oss.helm") version helmVersion
30+
id("io.github.build-extensions-oss.helm-publish") version helmVersion
3131
id("net.researchgate.release") version "3.1.0"
3232
id("com.vanniktech.maven.publish") version "0.34.0"
3333
id("org.jetbrains.kotlin.jvm") version kotlinVersion

0 commit comments

Comments
 (0)