@@ -31,7 +31,6 @@ def load_imports():
3131
3232@app .command (help = "Start Gaiaflow production-like services." )
3333def start (
34- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
3534 force_new : bool = typer .Option (
3635 False ,
3736 "--force-new" ,
@@ -42,6 +41,7 @@ def start(
4241):
4342 """"""
4443 imports = load_imports ()
44+ project_path = Path .cwd ()
4545 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
4646 project_path
4747 )
@@ -59,9 +59,9 @@ def start(
5959
6060@app .command (help = "Stop Gaiaflow production-like services." )
6161def stop (
62- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
6362):
6463 imports = load_imports ()
64+ project_path = Path .cwd ()
6565 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
6666 project_path
6767 )
@@ -78,7 +78,6 @@ def stop(
7878
7979@app .command (help = "Restart Gaiaflow production-like services." )
8080def restart (
81- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
8281 force_new : bool = typer .Option (
8382 False ,
8483 "--force-new" ,
@@ -88,6 +87,7 @@ def restart(
8887 ),
8988):
9089 imports = load_imports ()
90+ project_path = Path .cwd ()
9191 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
9292 project_path
9393 )
@@ -99,19 +99,20 @@ def restart(
9999 gaiaflow_path = gaiaflow_path ,
100100 user_project_path = user_project_path ,
101101 action = imports .BaseAction .RESTART ,
102+ force_new = force_new
102103 )
103104
104105
105106@app .command (
106107 help = "Containerize your package into a docker image inside the minikube cluster."
107108)
108109def dockerize (
109- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
110110 image_name : str = typer .Option (
111111 DEFAULT_IMAGE_NAME , "--image-name" , "-i" , help = ("Name of your image." )
112112 ),
113113):
114114 imports = load_imports ()
115+ project_path = Path .cwd ()
115116 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
116117 project_path
117118 )
@@ -133,9 +134,9 @@ def dockerize(
133134 "cluster. To be used only when debugging required."
134135)
135136def create_config (
136- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
137137):
138138 imports = load_imports ()
139+ project_path = Path .cwd ()
139140 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
140141 project_path
141142 )
@@ -152,13 +153,13 @@ def create_config(
152153
153154@app .command (help = "Create secrets to provide to the production-like environment." )
154155def create_secret (
155- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
156156 name : str = typer .Option (..., "--name" , help = "Name of the secret" ),
157157 data : list [str ] = typer .Option (
158158 ..., "--data" , help = "Secret data as key=value pairs"
159159 ),
160160):
161161 imports = load_imports ()
162+ project_path = Path .cwd ()
162163 secret_data = imports .parse_key_value_pairs (data )
163164 print (secret_data , name )
164165 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
@@ -179,12 +180,11 @@ def create_secret(
179180
180181@app .command (
181182 help = "Clean Gaiaflow production-like services. This will only remove the "
182- "minikube speicifc things. To remove local docker stuff, use the dev mode."
183+ "minikube specific things. To remove local docker stuff, use the dev mode."
183184)
184- def cleanup (
185- project_path : Path = typer .Option (..., "--path" , "-p" , help = "Path to your project" ),
186- ):
185+ def cleanup ():
187186 imports = load_imports ()
187+ project_path = Path .cwd ()
188188 gaiaflow_path , user_project_path = imports .create_gaiaflow_context_path (
189189 project_path
190190 )
0 commit comments