Chris Hairfield
10/12/2022, 9:26 PMsandbox
environment with --fast
registration, which is pretty awesome. But now I’m stuck trying to set inputs specific to developing in sandbox
(e.g., hostname of an external service running on my local machine).
Question: How do I enable a schedule with specified inputs that override default_inputs
whenever the scheduler invokes my workflow?
What I think I want is a commandline like:
flytectl update launchplan -p {project} -d {domain} {lp_name} --version {version} --activate --execFile exec_spec.yaml
As a test, when I try to follow this line from the docs and omit a required input from the LaunchPlan.get_or_create
call, then my schedule simply doesn’t run when actived:
Launch plans do not necessarily contain the entire set of required workflow inputs
I hope I’m just missing something! Thanks.Yee
Chris Hairfield
10/12/2022, 11:22 PMYee
Chris Hairfield
10/12/2022, 11:24 PMYee
Chris Hairfield
10/12/2022, 11:24 PM@workflow
def wf(ip: str, args: List[str]):
prepared = prepare_map_inputs(args=args, ip=ip)
return map_task(task_name)(input=prepared)
Yee
Chris Hairfield
10/12/2022, 11:27 PMYee
Chris Hairfield
10/12/2022, 11:28 PMYee
Chris Hairfield
10/12/2022, 11:30 PMlaunch_plan = LaunchPlan.get_or_create(
workflow=wf,
name="lp",
default_inputs={
"args": ["arg1", "arg2"],
"ip": "<http://kubernetes-host:8080>",
},
schedule=CronSchedule(
schedule="*/1 * * * *", # a testing schedule of 1 minute
),
)
Yee
Chris Hairfield
10/12/2022, 11:31 PM"<http://host.docker.internal:8080>"
)Yee
Chris Hairfield
10/12/2022, 11:32 PMYee
Chris Hairfield
10/12/2022, 11:35 PM