Merge ~hloeung/content-cache-charm:cleanup into content-cache-charm:master

Proposed by Haw Loeung
Status: Merged
Approved by: Haw Loeung
Approved revision: 74c23bd858a387d823dad1bc9aba6ed9c6b29296
Merged at revision: 784288f77832ef2e2907c94c59c13bdff3249111
Proposed branch: ~hloeung/content-cache-charm:cleanup
Merge into: content-cache-charm:master
Diff against target: 44 lines (+3/-5)
1 file modified
reactive/content_cache.py (+3/-5)
Reviewer Review Type Date Requested Status
Stephen Muss (community) Approve
Canonical IS Reviewers Pending
Review via email: mp+385342@code.launchpad.net

Commit message

PEP8 F522 fixes

To post a comment you must log in.
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
Stephen Muss (stephenmuss) wrote :

lgtm

review: Approve
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision 784288f77832ef2e2907c94c59c13bdff3249111

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/reactive/content_cache.py b/reactive/content_cache.py
2index 576980f..6e106d6 100644
3--- a/reactive/content_cache.py
4+++ b/reactive/content_cache.py
5@@ -341,12 +341,10 @@ def configure_nagios():
6 cache_port = site_conf['cache_port']
7
8 default_port = 80
9- url = 'http://{}'.format(site)
10 tls_cert_bundle_path = site_conf.get('tls-cert-bundle-path')
11 tls = ''
12 if tls_cert_bundle_path:
13 default_port = 443
14- url = 'https://{}'.format(site)
15 tls = ' --ssl=1.2 --sni'
16
17 frontend_port = site_conf.get('port') or default_port
18@@ -368,7 +366,7 @@ def configure_nagios():
19 cmd = (
20 '/usr/lib/nagios/plugins/check_http -I 127.0.0.1 -H {site_name}'
21 ' -p {port}{tls} -j {method} -u {path}{token}'.format(
22- site_name=site_name, port=frontend_port, method=method, url=url, path=path, token=token, tls=tls
23+ site_name=site_name, port=frontend_port, method=method, path=path, token=token, tls=tls
24 )
25 )
26 if 'nagios-expect' in loc_conf:
27@@ -380,7 +378,7 @@ def configure_nagios():
28 cmd = (
29 '/usr/lib/nagios/plugins/check_http -I 127.0.0.1 -H {site_name}'
30 ' -p {cache_port} -j {method} -u {path}{token}'.format(
31- site_name=site_name, cache_port=cache_port, method=method, url=url, path=path, token=token
32+ site_name=site_name, cache_port=cache_port, method=method, path=path, token=token
33 )
34 )
35 if 'nagios-expect' in loc_conf:
36@@ -394,7 +392,7 @@ def configure_nagios():
37 cmd = (
38 '/usr/lib/nagios/plugins/check_http -I 127.0.0.1 -H {site_name} -p {backend_port}'
39 ' -j {method} -u {path}'.format(
40- site_name=site_name, backend_port=backend_port, method=method, url=url, path=path
41+ site_name=site_name, backend_port=backend_port, method=method, path=path
42 )
43 )
44 nrpe_setup.add_check(

Subscribers

People subscribed via source and target branches