Skip to content

Commit

Permalink
native image fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Andreas Mautsch committed Nov 25, 2023
1 parent 98de237 commit 3f13bd1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ plugins {
id("org.springframework.boot") version "3.2.0"
id("io.spring.dependency-management") version "1.1.4"
id("org.graalvm.buildtools.native") version "0.9.28"
id("com.google.cloud.tools.jib") version "3.3.2"
id("com.google.cloud.tools.jib") version "3.4.0"
}

repositories {
Expand Down Expand Up @@ -104,6 +104,7 @@ tasks.register("dockerImageNativeNoTest") {group = "build"; dependsOn("bootJar")
jib.from.image = "ubuntu:22.04"
jib.to.image = "${dockerRegistry}/${project.name}-native" + (if (System.getProperty("os.arch").equals("aarch64")) "-arm64v8" else "") + ":${project.version}"
jib.pluginExtensions { pluginExtension {properties = mapOf("imageName" to "application"); implementation = "com.google.cloud.tools.jib.gradle.extension.nativeimage.JibNativeImageExtension" }}
val platform = com.google.cloud.tools.jib.gradle.PlatformParameters(); platform.os = "linux"; platform.architecture = (if (System.getProperty("os.arch").equals("aarch64")) "arm64" else "amd64"); jib.from.platforms.set(listOf(platform))
}
finalizedBy("jib")
}
Expand Down

0 comments on commit 3f13bd1

Please sign in to comment.