gorgeous-magician-44276
07/25/2024, 8:44 PMDiagnostics:
pulumi:pulumi:Stack (infra-eks-utils-dev):
error: preview failed
kubernetes:opensearch.opster.io/v1:OpenSearchCluster (opensearch-cluster/opensearch-cluster):
error: Preview failed: 1 error occurred:
* the Kubernetes API server reported that "opensearch-cluster/opensearch-cluster" failed to fully initialize or become live: Server-Side Apply field conflict detected. See <https://www.pulumi.com/registry/packages/kubernetes/how-to-guides/managing-resources-with-server-side-apply/#handle-field-conflicts-on-existing-resources> for troubleshooting help.
The resource managed by field manager "pulumi-kubernetes-fa75979c" had an apply conflict: Apply failed with 1 conflict: conflict with "Go-http-client" using opensearch.opster.io/v1: .spec.nodePools
And what's interesting pods are running fine..?
holms@Romans-MBP-2 ~/D/p/i/i/eks_utils (main)> kubectl get pods -n=opensearch-cluster
NAME READY STATUS RESTARTS AGE
opensearch-cluster-dashboards-68bfb4bd48-xzxjs 1/1 Running 0 43m
opensearch-cluster-masters-0 1/1 Running 0 43m
opensearch-cluster-masters-1 1/1 Running 0 41m
opensearch-cluster-masters-2 1/1 Running 0 39m
opensearch-cluster-securityconfig-update-j4cdd 0/1 Completed 0 43m
holms@Romans-MBP-2 ~/D/p/i/i/eks_utils (main)> kubectl get deployments -n=opensearch-cluster
NAME READY UP-TO-DATE AVAILABLE AGE
opensearch-cluster-dashboards 1/1 1 1 45m
Source here: http://dpaste.com//DFR3MJABP and here http://dpaste.com//7RHPZHHX6gorgeous-magician-44276
07/25/2024, 10:02 PMmodern-zebra-45309
07/25/2024, 10:06 PMmodern-zebra-45309
07/25/2024, 10:07 PMgorgeous-magician-44276
07/25/2024, 10:07 PMgorgeous-magician-44276
07/25/2024, 10:08 PMmodern-zebra-45309
07/25/2024, 10:09 PMgorgeous-magician-44276
07/25/2024, 10:11 PMgorgeous-magician-44276
07/25/2024, 10:11 PMmodern-zebra-45309
07/25/2024, 10:11 PMmodern-zebra-45309
07/25/2024, 10:12 PMmetadata.managedFields
, see this example in the k8s docsgorgeous-magician-44276
07/25/2024, 10:14 PMopts=ResourceOptions(ignore_changes=["prop"]))
just not sure what to ignore.modern-zebra-45309
07/25/2024, 10:15 PMgorgeous-magician-44276
07/25/2024, 10:15 PMmodern-zebra-45309
07/25/2024, 10:16 PMmodern-zebra-45309
07/25/2024, 10:17 PMgorgeous-magician-44276
07/25/2024, 10:17 PMgorgeous-magician-44276
07/25/2024, 10:17 PMgorgeous-magician-44276
07/25/2024, 10:18 PMmodern-zebra-45309
07/25/2024, 10:18 PMgorgeous-magician-44276
07/25/2024, 10:20 PMmodern-zebra-45309
07/25/2024, 10:20 PMgorgeous-magician-44276
07/25/2024, 10:21 PMdata={
"foo": "bar",
},
gorgeous-magician-44276
07/25/2024, 10:22 PMmodern-zebra-45309
07/25/2024, 10:23 PMannotations={
"<http://pulumi.com/patchForce|pulumi.com/patchForce>": "true",
},
modern-zebra-45309
07/25/2024, 10:24 PMgorgeous-magician-44276
07/25/2024, 10:26 PMmodern-zebra-45309
07/25/2024, 10:26 PMkubectl apply --force-conflicts=true
modern-zebra-45309
07/25/2024, 10:27 PMCould you please tell me what instead of "example" should be in place π ?The name of your resource. You have to modify your current resource definition. Like this:
modern-zebra-45309
07/25/2024, 10:28 PMresource = k8s.some.Resource("my-resource", metadata={"name": "my-resource-1"})
New:
resource = k8s.some.Resource("my-resource", metadata={"name": "my-resource-1", "annotations": {"<http://pulumi.com/patchForce|pulumi.com/patchForce>": "true"}})
modern-zebra-45309
07/25/2024, 10:29 PMgorgeous-magician-44276
07/25/2024, 10:29 PMgorgeous-magician-44276
07/25/2024, 10:32 PMopensearch_cluster_chart = k8s.helm.v3.Chart(
"opensearch-cluster",
metadata={
"name": "opensearch-cluster",
"annotations": {"pulumi.com/patchForce": "true"}
},
k8s.helm.v3.ChartOpts(
chart="opensearch-cluster",
version="2.6.1",
fetch_opts=k8s.helm.v3.FetchOpts(
repo="<https://opensearch-project.github.io/opensearch-k8s-operator/>"
),
namespace=namespace,
values=values
),
opts=pulumi.ResourceOptions(provider=k8s_provider)
)
gorgeous-magician-44276
07/25/2024, 10:32 PMgorgeous-magician-44276
07/25/2024, 10:32 PMprovider = kubernetes.Provider("k8s", enable_server_side_apply=True)
gorgeous-magician-44276
07/25/2024, 10:34 PMopts=pulumi.ResourceOptions(
provider=k8s_provider,
depends_on=[opensearch_ns],
custom_metadata={"annotations": {"<http://pulumi.com/patchForce|pulumi.com/patchForce>": "true"}}
)
gorgeous-magician-44276
07/25/2024, 11:46 PMgorgeous-magician-44276
07/26/2024, 2:00 AMkubernetes:<http://opensearch.opster.io/v1:OpenSearchCluster|opensearch.opster.io/v1:OpenSearchCluster> (opensearch-cluster:opensearch-cluster/opensearch-cluster):
error: resource "urn:pulumi:dev::infra-eks-utils::kubernetes:<http://helm.sh/v4:Chart$kubernetes:opensearch.opster.io/v1:OpenSearchCluster::opensearch-cluster:opensearch-cluster/opensearch-cluster|helm.sh/v4:Chart$kubernetes:opensearch.opster.io/v1:OpenSearchCluster::opensearch-cluster:opensearch-cluster/opensearch-cluster>" was not successfully created by the Kubernetes API server: Server-Side Apply field conflict detected. See <https://www.pulumi.com/registry/packages/kubernetes/how-to-guides/managing-resources-with-server-side-apply/#handle-field-conflicts-on-existing-resources> for troubleshooting help.
The resource managed by field manager "pulumi-kubernetes-725b70ee" had an apply conflict: Apply failed with 1 conflict: conflict with "Go-http-client" using <http://opensearch.opster.io/v1|opensearch.opster.io/v1>: .spec.nodePools
gorgeous-magician-44276
07/26/2024, 2:00 AMmodern-zebra-45309
07/26/2024, 7:34 AMmodern-zebra-45309
07/26/2024, 7:39 AMglamorous-holiday-93698
07/26/2024, 8:51 AMgorgeous-magician-44276
07/26/2024, 12:04 PMmodern-zebra-45309
07/26/2024, 12:06 PMPulumi ignores a property by using the old value from the state instead of the value provided by the Pulumi program when determining whether an update or replace is needed. Ignored properties will still be used from the program when there is no previous value in the state, most importantly when creating the resource.see https://www.pulumi.com/docs/concepts/options/ignorechanges/
gorgeous-magician-44276
07/26/2024, 1:26 PMgorgeous-magician-44276
07/26/2024, 1:30 PMmodern-zebra-45309
07/26/2024, 2:18 PMglamorous-holiday-93698
07/26/2024, 2:20 PMglamorous-holiday-93698
07/26/2024, 2:20 PMglamorous-holiday-93698
07/26/2024, 2:20 PMglamorous-holiday-93698
07/26/2024, 2:20 PM