-
Notifications
You must be signed in to change notification settings - Fork 117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add pattern matching and multiple paths to watch configuration #740
base: main
Are you sure you want to change the base?
Conversation
44b96f9
to
b0bb892
Compare
While I can see some benefits having support for multiple values in |
9ce61ad
to
ffa8777
Compare
Signed-off-by: Joana Hrotkó <joana.hrotko@gmail.com>
Signed-off-by: Joana Hrotkó <joana.hrotko@gmail.com>
ffa8777
to
15ccb87
Compare
if you take a look at the original issue, the user is requesting for both changes. On a first approach I thought they were hand in hand however with the latest changes is a nice to have. Looking at some existing watch configurations a lot of users are repeating actions (ex.: rebuild) with a different path and I think it would be a nice addition to add multiple path to each action in order to reduce repetition in a compose file. |
Signed-off-by: Joana Hrotkó <joana.hrotko@gmail.com>
15ccb87
to
07d331d
Compare
on docker/compose#12544 user requests as "nice to have" some way to avoid duplication when multiple patterns must apply to the same action. The challenge we have then is to find a base develop:
watch:
- action: rebuild
path: frontend
include:
- *.json
- *.js |
This PR enhances the watch configuration by introducing support for multiple paths and pattern matching under
services.develop.watch.path
. This update allows more flexibility in defining file-watching behavior forrebuild
andrestart
actions.Example:
This PoC is based on the request of #12544.
As discussed in this issue, given the restrictions of
sync
actions that require a 1:1 relation betweenpath
andtarget
, I would propose to move this functionality to a new keywordpaths
that would be available forrebuild
andrestart
actions only.Related compose PR