Brian Roepke
09/12/2024, 6:24 PMMarvin
09/12/2024, 6:24 PMBrian Roepke
09/12/2024, 6:24 PMMarvin
09/12/2024, 6:25 PMjob_variables
parameter in your deployment configuration.
3. Static vs. Dynamic Infrastructure:
- Static Infrastructure: If you have flows running regularly, use the serve
method from the Flow object or the serve utility to manage multiple flows simultaneously.
- Dynamic Infrastructure: Deploy the flows dynamically, allowing them to scale horizontally based on need.
4. Deployment Configuration: Use either the UI or CLI to run the deployment configuration. For example:
python
from prefect import flow
if __name__ == "__main__":
flow.from_source(
source="<https://github.com/prefecthq/demo.git>",
entrypoint="flow.py:my_flow",
).deploy(
name="my-flow",
work_pool_name="my-ecs-pool",
job_variables={"pip_packages": ["pandas", "prefect-aws"]},
)
For more detailed information, you can refer to the ECS guide:
- ECS Guide
Hope this helps!