mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-24 04:06:03 +00:00
Merge pull request #49033 from wwwtyro/rye/handle-prev-port-none
Automatic merge from submit-queue (batch tested with PRs 48231, 47377, 48797, 49020, 49033) prevent unsetting of nonexistent previous port in kubeapi-load-balancer charm **What this PR does / why we need it**: prevent unsetting of nonexistent previous port in kubeapi-load-balancer charm **Release note**: ```release-note prevent unsetting of nonexistent previous port in kubeapi-load-balancer charm ```
This commit is contained in:
commit
50ec4384ff
@ -54,6 +54,8 @@ def request_server_certificates(tls):
|
||||
def close_old_port():
|
||||
config = hookenv.config()
|
||||
old_port = config.previous('port')
|
||||
if not old_port:
|
||||
return
|
||||
try:
|
||||
hookenv.close_port(old_port)
|
||||
except CalledProcessError:
|
||||
|
Loading…
Reference in New Issue
Block a user