Conversation
|
@utkarsh867 this is what I got so far |
|
Great! Let me get through quickly. |
|
@yawjalik There are two scenarios here for the Docker image that we should handle.
All that happening automatic, without user prompt will be insane. The only catch to this I see is that Dockerhub images don't need a URL. Not sure how we can handle that. @98sean98 You have any ideas how to resolve this? |
|
Updates:
TODO:
|
Pretty good work.
in my experience, these are the requirements that aws, azure, and gcp sort of demand |
|
deploifai/cli/application/create.py
Outdated
| click.secho(f"\nApplication {application['name']} created successfully", fg="green") | ||
|
|
||
| # Poll for deployment status every 10 seconds | ||
| click.echo("Checking deployment status (this will take some time)... ", nl=False) |
There was a problem hiding this comment.
"Deploying application (this will take a few minutes, and it's safe to CTRL+C) ..."
deploifai/cli/application/create.py
Outdated
| # Format env | ||
| formatted_env = [] | ||
| for env_var in env: | ||
| key, val = env_var.split("=", maxsplit=1) |
There was a problem hiding this comment.
Catch python ValueError when env_var fails to unpack into a key-value pair, this would indicate that this env_var is faulty.
Print this env_var for the user, and abort the command
| @click.option( | ||
| "--env", | ||
| help="Environment variables for the container (e.g. --env path/to/env OR --env VAR1=VAL1 --env VAR2=VAL2)", | ||
| multiple=True, | ||
| ) |
There was a problem hiding this comment.
Add another --env-file option to read env files. This should be able to accept multiple files as well.
If the user uses both --env and --env-file options, just read everything and aggregate into one list.
deploifai/cli/application/create.py
Outdated
| { | ||
| "type": "list", | ||
| "name": "config", | ||
| "message": "Choose a size for the application", |
There was a problem hiding this comment.
Choose a size of the application ({provider})
|
@98sean98 removed config stuff and should be ready for merge? Any other issues? |
Implementing the command
deploifai application create NAME [FLAGS]Users can specify these using flags:
-i--image-tor--tag-por--portIf not provided, users will be prompted along with other details: