diff --git a/core/settings.py b/core/settings.py index 2e86b09..d07f2cb 100644 --- a/core/settings.py +++ b/core/settings.py @@ -17,7 +17,10 @@ MINT_SERVER_PORT = env.int("MINT_SERVER_PORT", default=3338) MINT_HOST = env.str("MINT_HOST", default="127.0.0.1") MINT_PORT = env.int("MINT_PORT", default=3338) -MINT_URL = f"http://{MINT_HOST}:{MINT_PORT}" +if MINT_HOST in ["localhost", "127.0.0.1"]: + MINT_URL = f"http://{MINT_HOST}:{MINT_PORT}" +else: + MINT_URL = f"https://{MINT_HOST}:{MINT_PORT}" LNBITS_ENDPOINT = env.str("LNBITS_ENDPOINT", default=None) LNBITS_KEY = env.str("LNBITS_KEY", default=None) diff --git a/poetry.lock b/poetry.lock index 3306de6..e5a2a9c 100644 --- a/poetry.lock +++ b/poetry.lock @@ -608,14 +608,15 @@ python-versions = ">=3.7" [[package]] name = "urllib3" -version = "1.23" +version = "1.26.12" description = "HTTP library with thread-safe connection pooling, file post, and more." category = "main" optional = false -python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, <4" +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*, !=3.5.*, <4" [package.extras] -secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "pyOpenSSL (>=0.14,<18.0.0)"] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)", "brotlipy (>=0.6.0)"] +secure = ["certifi", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "ipaddress", "pyOpenSSL (>=0.14)", "urllib3-secure-extra"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] [[package]] @@ -673,7 +674,7 @@ testing = ["func-timeout", "jaraco.itertools", "pytest (>=6)", "pytest-black (>= [metadata] lock-version = "1.1" python-versions = "^3.8" -content-hash = "8046f708fe138fcdb9c1e39e18e4c466292f183f0d1736ecee66ec4854ad54cc" +content-hash = "94ee00dcabb86013962ff90c7a2c1cd004ea4e0465236e714fc4aa1999bb23fd" [metadata.files] anyio = [ @@ -1139,8 +1140,8 @@ typing-extensions = [ {file = "typing_extensions-4.3.0.tar.gz", hash = "sha256:e6d2677a32f47fc7eb2795db1dd15c1f34eff616bcaf2cfb5e997f854fa1c4a6"}, ] urllib3 = [ - {file = "urllib3-1.23-py2.py3-none-any.whl", hash = "sha256:b5725a0bd4ba422ab0e66e89e030c806576753ea3ee08554382c14e685d117b5"}, - {file = "urllib3-1.23.tar.gz", hash = "sha256:a68ac5e15e76e7e5dd2b8f94007233e01effe3e50e8daddf69acfd81cb686baf"}, + {file = "urllib3-1.26.12-py2.py3-none-any.whl", hash = "sha256:b930dd878d5a8afb066a637fbb35144fe7901e3b209d1cd4f524bd0e9deee997"}, + {file = "urllib3-1.26.12.tar.gz", hash = "sha256:3fa96cf423e6987997fc326ae8df396db2a8b7c667747d47ddd8ecba91f4a74e"}, ] uvicorn = [ {file = "uvicorn-0.18.3-py3-none-any.whl", hash = "sha256:0abd429ebb41e604ed8d2be6c60530de3408f250e8d2d84967d85ba9e86fe3af"}, diff --git a/pyproject.toml b/pyproject.toml index cdea72d..547173a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -19,7 +19,7 @@ idna = "3.3" itsdangerous = "2.1.1" Jinja2 = "3.0.3" MarkupSafe = "2.1.1" -urllib3 = "1.23" +urllib3 = "^1.26.12" Werkzeug = "2.2.2" asgiref = "^3.5.2" pydantic = "^1.10.2"