Skip to content

Commit

Permalink
Merged branch bugfix/another-with-ports into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
horia141 committed Mar 4, 2024
1 parent 6a1289a commit b0cf0f0
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
3 changes: 3 additions & 0 deletions src/core/jupiter/core/utils/global_properties.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class GlobalProperties:
env: Env
hosting: Hosting
description: str
host: str
port: int
version: str
docs_init_workspace_url: str
Expand Down Expand Up @@ -58,6 +59,7 @@ def find_up_the_dir_tree(partial_path: Union[str, Path]) -> Path:
env = Env(cast(str, os.getenv("ENV")))
hosting = Hosting(cast(str, os.getenv("HOSTING")))
description = cast(str, os.getenv("DESCRIPTION"))
host = cast(str, os.getenv("HOST"))
port = int(cast(str, os.getenv("PORT")))
version = cast(str, os.getenv("VERSION"))
docs_init_workspace_url = cast(str, os.getenv("DOCS_INIT_WORKSPACE_URL"))
Expand All @@ -76,6 +78,7 @@ def find_up_the_dir_tree(partial_path: Union[str, Path]) -> Path:
env=env,
hosting=hosting,
description=description,
host=host,
port=port,
version=version,
docs_init_workspace_url=docs_init_workspace_url,
Expand Down
1 change: 1 addition & 0 deletions src/webapi/Config.project
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
ENV=local
HOSTING=local
BASENAME=jupiter-webapi
HOST=127.0.0.1
PORT=8010
DESCRIPTION="The Web RPC API client for Jupiter"
SQLITE_DB_URL=sqlite+aiosqlite:///jupiter.sqlite
Expand Down
4 changes: 3 additions & 1 deletion src/webapi/jupiter/webapi/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,9 @@ async def run(self) -> None:
)

config = uvicorn.Config(
self._fast_app, port=self._global_properties.port, log_level="info"
self._fast_app,
host=self._global_properties.host,
port=self._global_properties.port, log_level="info"
)
server = uvicorn.Server(config)
await server.serve()
Expand Down
6 changes: 4 additions & 2 deletions src/webui/Config.project.docker
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
_ENV=WILL-BE-FILLED-BY-RENDER
HOSTING=hosted-global
BASENAME=jupiter-webui
_HOST=WILL-BE-FILLED-BY-DOCKER-IN-RENDER
_PORT=WILL-BE-FILLED-BY-DOCKER-In-RENDER
TITLE="Jupiter"
DESCRIPTION="The Jupiter Web application"
LOCAL_WEBAPI_SERVER_URL="http://127.0.0.1:8010"
LOCAL_WEBAPI_PROGRESS_REPORTER_URL="ws://localhost:8010/progress-reporter"
LOCAL_WEBAPI_SERVER_URL="http://127.0.0.1:10000"
LOCAL_WEBAPI_PROGRESS_REPORTER_URL="ws://localhost:10000/progress-reporter"
_HOSTED_GLOBAL_WEBAPI_SERVER_PORT=WILL-BE-FILLED-BY-RENDER
_HOSTED_GLOBAL_WEBAPI_SERVER_PORT=WILL-BE-FILLED-BY-RENDER
DOCS_URL=https://jupiter-goals.readthedocs.io
Expand Down

0 comments on commit b0cf0f0

Please sign in to comment.