mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-11-29 08:25:10 +00:00
fix formatting issues
Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
1 parent
fa74a26042
commit
eb83e00011
134 files changed
+598
-720
No files matched your search
@@ -211,7 +211,6 @@ def webserver_disable(name, kind='config', apply_changes=True):
|
||||
|
||||
class WebserverChange(object):
|
||||
"""Context to restart/reload Apache after configuration changes."""
|
||||
|
||||
def __init__(self):
|
||||
"""Initialize the context object state."""
|
||||
self.actions_required = set()
|
||||
@@ -425,9 +424,10 @@ def diagnose_url_on_all(url, **kwargs):
|
||||
def diagnose_netcat(host, port, input='', negate=False):
|
||||
"""Run a diagnostic using netcat."""
|
||||
try:
|
||||
process = subprocess.Popen(
|
||||
['nc', host, str(port)], stdin=subprocess.PIPE,
|
||||
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
process = subprocess.Popen(['nc', host, str(port)],
|
||||
stdin=subprocess.PIPE,
|
||||
stdout=subprocess.PIPE,
|
||||
stderr=subprocess.PIPE)
|
||||
process.communicate(input=input.encode())
|
||||
if process.returncode != 0:
|
||||
result = 'failed'
|
||||
|
||||
Reference in new issue
Block a user