Skip to content
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

Fix file watcher #10420

Merged
merged 2 commits into from Feb 9, 2024
Merged

Fix file watcher #10420

merged 2 commits into from Feb 9, 2024

Conversation

juliens
Copy link
Member

@juliens juliens commented Feb 8, 2024

What does this PR do?

The PR adds some watcher on the file provider:

  • When using the filename field, we watch events on file and the parent directory instead of only the parent directory
  • When using the directory field, we watch the directory and all the files present in the directory (no sub-dir because sub-dir still doesn't work)

Motivation

Fixes #10409

More

  • Added/updated tests
  • Added/updated documentation

Additional Notes

In Docker (on Linux), if you mount a file directly, events are triggered on the file and not on the directory.

@traefiker traefiker added this to the 2.11 milestone Feb 8, 2024
@ldez ldez changed the title Fix file watcher. Fix file watcher Feb 8, 2024
@ldez ldez self-requested a review February 8, 2024 16:04
Copy link
Member

@ldez ldez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@nmengin nmengin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@traefiker traefiker merged commit 676de5f into traefik:v2.11 Feb 9, 2024
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants