Hello, I am using this video <https://youtu.be/q-s...
# ask-community
d
Hello, I am using this video

https://youtu.be/q-sl6bzi5fw

to create a ECS Cluster with prefect. It pulls from Prefect Image
prefecthq/prefect:2-python3.10
but I want to run a dbt command and dbt sits in another Repo, in ECR
<http://999999999999.dkr.ecr.us-east-1.amazonaws.com/analytics_dbt:latestI|999999999999.dkr.ecr.us-east-1.amazonaws.com/analytics_dbt:latestI>
I want to understand, how I can leverage the Prefect agent and execute dbt in another container? Should it lunch 2 containers?
d
Hi Dimon, You would need to create an ECS block for your dbt ECS image and then deploy the dbt Flow into this infrastructure:
Copy code
Deployment.build_from_flow(
    flow=flow,
    name=name,
    description=description,
    tags=tags,
    schedule=schedule,
    parameters=parameters,
    work_queue_name=work_queue_name,
    infrastructure=ECSTask.load(ECS_dbt_block_name),
)
Another approach is to
git clone
your dbt repo every time you start the ECS container (run the dbt Flow) in default ECS image.
d
Thank you, Dmytro.