Skip to content

Commit

Permalink
chore: Use new env key 'DBGPT_WEBSERVER_PORT'
Browse files Browse the repository at this point in the history
  • Loading branch information
fangyinc committed Apr 11, 2024
1 parent d8f82a8 commit 5e618e1
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .env.template
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#*******************************************************************#
#** Webserver Port **#
#*******************************************************************#
WEB_SERVER_PORT=5670
# DBGPT_WEBSERVER_PORT=5670

#*******************************************************************#
#*** LLM PROVIDER ***#
Expand Down
2 changes: 1 addition & 1 deletion dbgpt/_private/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def __init__(self) -> None:

# Gradio language version: en, zh
self.LANGUAGE = os.getenv("LANGUAGE", "en")
self.WEB_SERVER_PORT = int(os.getenv("WEB_SERVER_PORT", 5670))
self.DBGPT_WEBSERVER_PORT = int(os.getenv("DBGPT_WEBSERVER_PORT", 5670))

self.debug_mode = False
self.skip_reprompt = False
Expand Down
2 changes: 1 addition & 1 deletion dbgpt/app/dbgpt_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ def initialize_app(param: WebServerParameters = None, args: List[str] = None):

model_name = param.model_name or CFG.LLM_MODEL
param.model_name = model_name
param.port = param.port or CFG.WEB_SERVER_PORT
param.port = param.port or CFG.DBGPT_WEBSERVER_PORT
if not param.port:
param.port = 5670

Expand Down

0 comments on commit 5e618e1

Please sign in to comment.