CLI: Allows the server to disable SSL with an explicit flags
@@ -31,6 +31,7 @@ def parse_args():
"--security", type=str, default=None, choices=[None, "local"], help="The security protocol to use")
security.add_argument(
"--allow-read", type=bool, default=True, help="Allow read-only queries or not if security is active.")
+ security.add_argument("--disable-ssl", type=bool, default=False, help="Disables SSL if present, if False a SSL cert will be created for you")
security.add_argument("--tls-cert", type=str, default=None, help="Certificate file for TLS (in PEM format)")
security.add_argument("--tls-key", type=str, default=None, help="Private key file for TLS (in PEM format)")
@@ -61,6 +62,9 @@ def main(args=None):
args = parse_args()
# Handle SSL
+ if args["disable_ssl"]:
+ ssl_options = False
+ else:
ssl_certs = sum(args[x] is not None for x in ["tls_key", "tls_cert"])
if ssl_certs == 0:
ssl_options = None
