Closed so0k closed 2 years ago
command:
k2tf -f test-fixtures/replicationController.yml
expected
resource "kubernetes_replication_controller" "es" { metadata { name = "es" labels = { component = "elasticsearch" } } spec { replicas = 1 template { metadata { labels = { component = "elasticsearch" } } spec { volume { name = "storage" empty_dir {} } ...
got
resource "kubernetes_replication_controller" "es" { metadata { name = "es" labels = { component = "elasticsearch" } } spec { replicas = 1 template { metadata { labels = { component = "elasticsearch" } } spec { volume { name = "storage" } ...
problem: this causes a diff in plan:
# kubernetes_replication_controller.es will be updated in-place ~ resource "kubernetes_replication_controller" "es" { id = "default/es" # (1 unchanged attribute hidden) ~ spec { # (5 unchanged attributes hidden) ~ template { ~ spec { # (12 unchanged attributes hidden) ~ volume { name = "storage" - empty_dir {} } # (5 unchanged blocks hidden) } # (1 unchanged block hidden) } # (2 unchanged blocks hidden) } # (1 unchanged block hidden) }
I have no idea how k2tf works atm, I use it in make targets to automatically convert upstream bundles using kustomize into terraform modules, so I don't edit the generated results.
maybe this is related #29 ?
command:
expected
got
problem: this causes a diff in plan: