5151 "using the RAY_ADDRESS environment variable."
5252)
5353RAY_DASHBOARD_ADDRESS_HELP_STR = (
54- "Address to use to query the Ray dashboard agent (defaults to "
55- "http://localhost:52365 ). Can also be specified using the "
56- "RAY_AGENT_ADDRESS environment variable."
54+ "Address to use to query the Ray dashboard head (defaults to "
55+ "http://localhost:8265 ). Can also be specified using the "
56+ "RAY_DASHBOARD_ADDRESS environment variable."
5757)
5858
5959
@@ -128,6 +128,15 @@ def convert_args_to_dict(args: Tuple[str]) -> Dict[str, str]:
128128 return args_dict
129129
130130
131+ def warn_if_agent_address_set ():
132+ if "RAY_AGENT_ADDRESS" in os .environ :
133+ cli_logger .warning (
134+ "The `RAY_AGENT_ADDRESS` env var has been deprecated in favor of "
135+ "the `RAY_DASHBOARD_ADDRESS` env var. The `RAY_AGENT_ADDRESS` is "
136+ "ignored."
137+ )
138+
139+
131140@click .group (
132141 help = "CLI for managing Serve applications on a Ray cluster." ,
133142 context_settings = dict (help_option_names = ["--help" , "-h" ]),
@@ -240,12 +249,14 @@ def start(
240249@click .option (
241250 "--address" ,
242251 "-a" ,
243- default = os .environ .get ("RAY_AGENT_ADDRESS " , "http://localhost:52365 " ),
252+ default = os .environ .get ("RAY_DASHBOARD_ADDRESS " , "http://localhost:8265 " ),
244253 required = False ,
245254 type = str ,
246255 help = RAY_DASHBOARD_ADDRESS_HELP_STR ,
247256)
248257def deploy (config_file_name : str , address : str ):
258+ warn_if_agent_address_set ()
259+
249260 with open (config_file_name , "r" ) as config_file :
250261 config = yaml .safe_load (config_file )
251262
@@ -579,7 +590,7 @@ def run(
579590@click .option (
580591 "--address" ,
581592 "-a" ,
582- default = os .environ .get ("RAY_AGENT_ADDRESS " , "http://localhost:52365 " ),
593+ default = os .environ .get ("RAY_DASHBOARD_ADDRESS " , "http://localhost:8265 " ),
583594 required = False ,
584595 type = str ,
585596 help = RAY_DASHBOARD_ADDRESS_HELP_STR ,
@@ -595,6 +606,8 @@ def run(
595606 ),
596607)
597608def config (address : str , name : Optional [str ]):
609+ warn_if_agent_address_set ()
610+
598611 serve_details = ServeInstanceDetails (
599612 ** ServeSubmissionClient (address ).get_serve_details ()
600613 )
@@ -652,7 +665,7 @@ def config(address: str, name: Optional[str]):
652665@click .option (
653666 "--address" ,
654667 "-a" ,
655- default = os .environ .get ("RAY_AGENT_ADDRESS " , "http://localhost:52365 " ),
668+ default = os .environ .get ("RAY_DASHBOARD_ADDRESS " , "http://localhost:8265 " ),
656669 required = False ,
657670 type = str ,
658671 help = RAY_DASHBOARD_ADDRESS_HELP_STR ,
@@ -669,6 +682,8 @@ def config(address: str, name: Optional[str]):
669682 ),
670683)
671684def status (address : str , name : Optional [str ]):
685+ warn_if_agent_address_set ()
686+
672687 serve_details = ServeInstanceDetails (
673688 ** ServeSubmissionClient (address ).get_serve_details ()
674689 )
@@ -708,13 +723,15 @@ def status(address: str, name: Optional[str]):
708723@click .option (
709724 "--address" ,
710725 "-a" ,
711- default = os .environ .get ("RAY_AGENT_ADDRESS " , "http://localhost:52365 " ),
726+ default = os .environ .get ("RAY_DASHBOARD_ADDRESS " , "http://localhost:8265 " ),
712727 required = False ,
713728 type = str ,
714729 help = RAY_DASHBOARD_ADDRESS_HELP_STR ,
715730)
716731@click .option ("--yes" , "-y" , is_flag = True , help = "Bypass confirmation prompt." )
717732def shutdown (address : str , yes : bool ):
733+ warn_if_agent_address_set ()
734+
718735 if not yes :
719736 click .confirm (
720737 f"This will shut down Serve on the cluster at address "
0 commit comments