Skip to content

Commit

Permalink
fix(operator): handle tls disable/enable
Browse files Browse the repository at this point in the history
  • Loading branch information
nefelim4ag committed Jul 23, 2024
1 parent 815172a commit c00dedc
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions library/pingdom.py
Original file line number Diff line number Diff line change
Expand Up @@ -382,12 +382,18 @@ def modify_check(self, checkid: int, ingress):
}
logging.debug("Processing checkid: {}".format(checkid))

port = 80
if ingress.https:
value = ingress.https
if check_body['type'][type]['encryption'] != value:
logging.info(
" {}: {} -> {}".format('encryption', check_body['type'], value))
check_modify_request['encryption'] = value
port = 443

encryption = ingress.https
if check_body['type'][type]['encryption'] != encryption:
logging.info(
" {}: {} -> {}".format('encryption', check_body['type'], encryption))
check_modify_request['encryption'] = encryption

if check_body['type'][type]['port'] != port:
check_modify_request['port'] = port

if ingress.hosts:
value = ingress.hosts[0]
Expand Down

0 comments on commit c00dedc

Please sign in to comment.