Open tejaboppana opened 3 weeks ago
@tejaboppana thanks for flagging this
in step 1, did you create the Gateway
resource first (a.) and then create a EnvoyProxy
specifying the custom deployment name (b.) and then link the EnvoyProxy
resource to the Gateway
by editing it (c.) ?
For this case the I think the infra layer will create a new deployment with the new name but not delete the older deployment When a custom name is set, we also need to delete the older deployment https://github.com/envoyproxy/gateway/blob/0f4cb27f0110051f7811122a2dd73652c93a15b2/internal/infrastructure/kubernetes/proxy/resource_provider.go#L153
@arkodg I tried 2 things and below are my observations
Steps that you mentioned i.e a) Create Gateway
b) Create EnvoyProxy
c) Edit Gateway
to link it with EnvoyProxy
In this case a new deployment is created but the older deployment is not deleted which is not ideal. In addition to that, when I delete the Gateway
and EnvoyProxy
, I expected everything to be cleaned up. Only the older deployment and the service are deleted but the deployment with custom name is not deleted.
a) Create EnvoyProxy
b) Create Gateway
and link it to the EnvoyProxy
In this case the deployment is created with the custom name that I specified which is expected. But when I delete the Gateway
and EnvoyProxy
resources I expected the deployment and service to be deleted. However, this did not happen and both the deployment and service were still running. I had to manually delete them.
thanks, yeah an additional item here to delete based on gateway owning labels, and not just deployment to svc name https://github.com/envoyproxy/gateway/blob/0f4cb27f0110051f7811122a2dd73652c93a15b2/internal/infrastructure/kubernetes/infra_resource.go#L402
Description: Envoy Proxy deployment is not cleaned up when we customize the deployment name, replicas etc using EnvoyProxy resource,
Repro steps:
Environment: Envoy Gateway version - 1.1.2
Logs: I could not see any logs in Envoy Gateway pods when I deleted the Gateway.