Hello! Can anyone advise how to manage multiple d...
# prefect-cloud
c
Hello! Can anyone advise how to manage multiple docker build and docker push directives (dev, prd builds, pushes to different dev, prd ECR , in multiple AWS accounts)? I have the following:
Copy code
# build section allows you to manage and build docker images
build:
- prefect_docker.deployments.steps.build_docker_image:
    id: <DEV NAME>
    requires: prefect-docker>=0.4.0
    image_name: "<AWS ECR>/<DEV NAME>"
    tag: latest
    dockerfile: <DOCKERFILE>
- prefect_docker.deployments.steps.build_docker_image:
    id: <PRD NAME>
    requires: prefect-docker>=0.4.0
    image_name: "<AWS ECR>/<PRD NAME>"
    tag: latest
    dockerfile: <DOCKERFILE>

# push section allows you to manage if and how this project is uploaded to remote locations
push:
- prefect_docker.deployments.steps.push_docker_image:
    requires: prefect-docker>=0.4.0
    image_name: '{{ <DEV NAME>.image_name }}'
    tag: '{{ <DEV NAME>.tag }}'
- prefect_docker.deployments.steps.push_docker_image:
    requires: prefect-docker>=0.4.0
    image_name: '{{ <PRD NAME>.image_name }}'
    tag: '{{ <PRD NAME>.tag }}'

# the deployments section allows you to provide configuration for deploying flows
deployments:
...
and when I try doing a build it is attempting to push to the dev environment What am I doing wrong?
In case anyone hits this - Using multiple prefect.yaml type files, and specifying the required file when running prefect, works-for-me (this only works with recent prefect)