How do you perform a loop with an orb? I’m using the below orb but need to build multiple images with docker files in different folders, how would I dynamically change the parameters path and repo? I’m considering using docker-compose for this, but that still won’t address dynamically changing the ECR, for each image to be pushed
orbs:
aws-ecr: circleci/aws-ecr@x.y.z
version: 2.1
workflows:
build_and_push_image:
jobs:
- aws-ecr/build-and-push-image:
account-url: AWS_ECR_ACCOUNT_URL_ENV_VAR_NAME
aws-access-key-id: ACCESS_KEY_ID_ENV_VAR_NAME
aws-secret-access-key: SECRET_ACCESS_KEY_ENV_VAR_NAME
context: myContext
create-repo: true
dockerfile: myDockerfile
no-output-timeout: 20m
path: pathToMyDockerfile
profile-name: myProfileName
region: AWS_REGION_ENV_VAR_NAME
repo: myECRRepository
skip-when-tags-exist: false
tag: ‘latest,myECRRepoTag’