[piped] Implement regex-based dynamic changes in the event watcher
What would you like to be added: Currently, the event watcher modifies specific locations in a designated file, making it dependent solely on yaml files. To enhance flexibility, we propose adding a feature to identify and modify matching sections using regular expressions.
For instance:
terraform.tfvars
batch_image_uri = "{account_id}.dkr.ecr.ap-northeast-1.amazonaws.com/{project}-{application_name}:rc-202309111328"
dbt_image_uri = "{account_id}.dkr.ecr.ap-northeast-1.amazonaws.com/{project}-{application_name}::rc-202309121257"
refresher_image_uri = "{account_id}.dkr.ecr.ap-northeast-1.amazonaws.com/{project}-{application_name}::rc-202307140930"
app.pipecd.yaml
eventWatcher:
- matcher:
name: stg-service-data-image-update
handler:
type: GIT_UPDATE
config:
commitMessage: "[stg] Upgrade service-data service to the latest version"
replacements:
- file: terraform.tfvars
regex: "{account_id}.dkr.ecr.ap-northeast-1.amazonaws.com/{project}-{application_name}:(rc-[0-9]{12})"
Why is this needed:
Sounds good to me 👍
This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.
This issue was closed because it has been stalled for 7 days with no activity. Feel free to reopen if still applicable.