-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Default to Docker()
storage?
#1044
Comments
Makes sense to me. I'm concerned that we're starting to have a creeping pattern of "we want this thing to be instantiated automatically, but we need to provide init arguments" and our config is going to become crowded (and stale). Perhaps there's a clean way to mark init arguments as being read from config values (or, more likely, env vars), similar to how we use Something like: class MyClass:
@defaults_from_config(a="defaults.myclass.a", b="another_thing.myclass.b")
def __init__(self, a=1, b=2):
pass This way, a and b have Pythonic defaults, but can use Maybe too crazy / overengineered? |
Hmmmmm I'm definitely intrigued by this. So the idea here is that we don't have to populate these default values in our |
Yeah I'm on board with this |
OK so I decided I'm uncomfortable with a default
This would allow for the following lightning fast deploy: from prefect import Flow
Flow("speedy").deploy("My Project", registry_url="cicdw", image_name="speedy-flow") |
This was closed with #1337 |
Question: now that initializing
Docker
storage sets sensible defaults forbase_image
andprefect_version
, and additionally installskubernetes
extras, should we default to an unmodifiedDocker()
class for every Flow? I.e.,I don't believe this has any consequences for users not deploying their Flows to Cloud (because
flow.serialize
defaults to usingbuild=False
), but does allow simple Flows with no extraneous dependencies to be deployed with ease.This would require us to introduce one additional configuration setting for the
registry_url
, as we don't want to set any public defaults here, but could read a default value from a user'sconfig
or environment variable.cc: @jlowin @joshmeek
The text was updated successfully, but these errors were encountered: