deviceinsight / helm-maven-plugin

Maven Plugin for Helm Charts
Apache License 2.0
46 stars 22 forks source link

Make package goal more lenient #52

Closed ezienecker closed 4 years ago

ezienecker commented 4 years ago

Since the following commit an exception is thrown if a property cannot be reolved.

https://github.com/deviceinsight/helm-maven-plugin/commit/9b8ceca8d253d4152ad654c6977972a99ea00b71

It would be sufficient if you logged a warning instead.

Caused by: java.lang.IllegalStateException: Could not resolve property: 'test' used in file: '/home/test/projects/test/test/target/helm/test/templates/deployment.yaml'
    at com.deviceinsight.helm.PackageMojo.findPropertyValue (PackageMojo.kt:160)
    at com.deviceinsight.helm.PackageMojo.access$findPropertyValue (PackageMojo.kt:29)
    at com.deviceinsight.helm.PackageMojo$processHelmConfigFiles$processedFiles$2$$special$$inlined$use$lambda$1$1.invoke (PackageMojo.kt:133)
    at com.deviceinsight.helm.PackageMojo$processHelmConfigFiles$processedFiles$2$$special$$inlined$use$lambda$1$1.invoke (PackageMojo.kt:29)
    at kotlin.text.Regex.replace (Regex.kt:159)
    at com.deviceinsight.helm.PackageMojo$processHelmConfigFiles$processedFiles$2$$special$$inlined$use$lambda$1.invoke (PackageMojo.kt:130)
    at com.deviceinsight.helm.PackageMojo$processHelmConfigFiles$processedFiles$2$$special$$inlined$use$lambda$1.invoke (PackageMojo.kt:29)
    at kotlin.sequences.TransformingSequence$iterator$1.next (Sequences.kt:172)
    at com.deviceinsight.helm.PackageMojo$processHelmConfigFiles$processedFiles$2.invoke (PackageMojo.kt:171)
    at com.deviceinsight.helm.PackageMojo$processHelmConfigFiles$processedFiles$2.invoke (PackageMojo.kt:29)
    at kotlin.sequences.SequencesKt___SequencesKt$onEach$1.invoke (_Sequences.kt:1352)
    at kotlin.sequences.TransformingSequence$iterator$1.next (Sequences.kt:172)
    at kotlin.sequences.SequencesKt___SequencesKt.toCollection (_Sequences.kt:722)
    at kotlin.sequences.SequencesKt___SequencesKt.toMutableList (_Sequences.kt:752)
    at kotlin.sequences.SequencesKt___SequencesKt.toList (_Sequences.kt:743)
    at com.deviceinsight.helm.PackageMojo.processHelmConfigFiles (PackageMojo.kt:144)
    at com.deviceinsight.helm.PackageMojo.execute (PackageMojo.kt:74)
ezienecker commented 4 years ago

https://github.com/deviceinsight/helm-maven-plugin/pull/54

pvorb commented 4 years ago

Closed by #54