Hey I'm looking into giving this a shot so maybe I...
# kotlin-toolchain
g
Hey I'm looking into giving this a shot so maybe I can provide some feedback, but I already encountered the first road block hehe How can I configure some plugin settings like I would in gradle, for example:
Copy code
jib {
    from {
        image = "amazoncorretto:25-al2023-headless"
    }

    to {
        image = "<http://ghcr.io/${project.property(|ghcr.io/${project.property(>"ghcrOrg")}/$name"
        tags = setOf(System.getenv("CIRCLE_SHA1"), version.toString(), "latest")
        auth {
            username = System.getenv("GITHUB_ACTOR")
            password = System.getenv("GITHUB_TOKEN")
        }
    }

    container {
        jvmFlags = listOf(
            "-XX:+PrintCommandLineFlags",
            "-XshowSettings:vm",
            "-XX:MinRAMPercentage=50.0",
            "-XX:MaxRAMPercentage=50.0"
//            "-XX:+PrintFlagsFinal",
//            "-Xlog:os+container=trace"
        )
    }
}
👍 1
j
Hey, sorry that I missed your question for so long. When you write a plugin, you can define a Kotlin interface that represents the plugin settings, and then configure values for it in the
module.yaml
file of the module(s) enabling the plugin. You can have a look at my Jib plugin implementation as an example: https://github.com/joffrey-bion/amper-jib-plugin-example/blob/main/jib-plugin/src/settings.kt
By the way, you can find the docs about how to add plugin settings here in the quick start: https://kotlin-toolchain.org/latest/user-guide/plugins/quick-start/#adding-plugin-settings And more details here: https://kotlin-toolchain.org/latest/user-guide/plugins/topics/configuration/