mirror of
https://github.com/opentofu/opentofu.git
synced 2024-12-28 18:01:01 -06:00
rancher_stack: Only read compose when catalog_id is empty (#11593)
This commit is contained in:
parent
89acb5811a
commit
a3bfc5e8b3
@ -155,8 +155,12 @@ func resourceRancherStackRead(d *schema.ResourceData, meta interface{}) error {
|
||||
d.Set("name", stack.Name)
|
||||
dockerCompose := strings.Replace(config.DockerComposeConfig, "\r", "", -1)
|
||||
rancherCompose := strings.Replace(config.RancherComposeConfig, "\r", "", -1)
|
||||
d.Set("docker_compose", dockerCompose)
|
||||
d.Set("rancher_compose", rancherCompose)
|
||||
|
||||
catalogId := d.Get("catalog_id")
|
||||
if catalogId == "" {
|
||||
d.Set("docker_compose", dockerCompose)
|
||||
d.Set("rancher_compose", rancherCompose)
|
||||
}
|
||||
d.Set("rendered_docker_compose", dockerCompose)
|
||||
d.Set("rendered_rancher_compose", rancherCompose)
|
||||
d.Set("environment_id", stack.AccountId)
|
||||
|
Loading…
Reference in New Issue
Block a user