Closed LeoLiuYan closed 2 years ago
Please answer these questions before submitting your issue. Thanks!
import base.pkg.kusion_models.kube.frontend import base.pkg.kusion_models.kube.frontend.container import base.pkg.kusion_models.kube.frontend.container.probe import base.pkg.kusion_models.kube.frontend.container.lifecycle as lc import base.pkg.kusion_models.kube.templates.resource as res_tpl # The application configuration in stack will overwrite # the configuration with the same attribute in base. appConfiguration: frontend.Server { image = "gcr.io/google-samples/gb-frontend:v4-test" schedulingStrategy.resource = res_tpl.tiny mainContainer: container.Main { lifecycle: lc.Lifecycle { preStop = probe.Exec { command = ["/bin/sh", "-c", "echo 1"] } } } }
Kusion compile success.
---> File /Users/liuyan_1/Projects/github/konfig/base/pkg/kusion_models/kube/utils/container_frontend2kube.k:96 96 | } if c.lifecycle.preStop.type == "exec" else Undefined -> Failure schema 'base.pkg.kusion_models.kube.frontend.container.probe.Exec' attribute 'type' not found
releaseVersion: v0.5.3 gitInfo: latestTag: v0.5.3 commit: 7611976b68b1a5124e801a18a94072222ea88851 treeState: clean buildInfo: goVersion: go1.17.12 GOOS: linux GOARCH: amd64 numCPU: 2 compiler: gc buildTime: "2022-08-05 09:10:29" dependency: kclvmgoVersion: v0.4.3-alpha.1 kclPluginVersion: v0.4.1-alpha2
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
konfig/appops/guestbook-frontend/test/main.k
2. What did you expect to see? (Required)
Kusion compile success.
3. What did you see instead (Required)
4. What is your KusionStack components version? (Required)