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

Debug logging? #1

Closed
ianneub opened this issue Nov 9, 2023 · 6 comments · Fixed by #2
Closed

Debug logging? #1

ianneub opened this issue Nov 9, 2023 · 6 comments · Fixed by #2
Milestone

Comments

@ianneub
Copy link

ianneub commented Nov 9, 2023

Hello @dkreuer !

First off I wanted to let you know this project is exactly what I was looking for. A way to implement Fail2Ban in Traefik based on Unauthorized access. Thank you!

I tried setting the logLevel setting to DEBUG but didn't see any output. I also didn't see any output with INFO.

middlewares:
  fail2ban:
    plugin:
      fail2ban:
        logLevel: DEBUG
experimental:
  plugins:
    fail2ban:
      moduleName: "github.com/juitde/traefik-plugin-fail2ban"
      version: "v0.1.0"

Maybe I've got it configured wrong? What kind of output should we expect to see?

I'm using this in a Docker container if that might impact things.

Thank you!

@dkreuer
Copy link
Member

dkreuer commented Nov 9, 2023

Hello @ianneub!

Great to hear that the module is of use for others! Unfortunately there is no logging implemented at all since working priorities shifted after implementing the minimal required features. But I‘m willing to extend the plugin with detailed logging if that helps?

@ianneub
Copy link
Author

ianneub commented Nov 10, 2023

Thanks @dkreuer I was able to verify that everything is working as expected without the logging. Yesterday I was unsure if I had configured it correctly because I didn't see any logging at all. Maybe a change to the README removing/commenting out the logging section would be nice?

Up to you if you want to keep this issue open or not, I'm OK to close it on my side.

Thanks again for your help and the project!

@fliot
Copy link

fliot commented Jan 11, 2024

Hello,
Same as @dkreuer , your project is exactly what I was looking for. I spent hours trying to patch myself the @tomMoulard implementation, but you did everything well, congrats.
And again, as @dkreuer indeed, just a single additional log in Traefik pipe out to claim "ip xx.xx.xx.xx have been blocked for YYmin" would be super.
I would do such patch by myself, but I didn't found a testing way without completely publishing on Traefik Public Catalog, on my name...
Let me know your though, worst case I will do it.
Cheers.

@dkreuer
Copy link
Member

dkreuer commented Jan 11, 2024

I'll implement some logging for the blocking case in the next days. Thanks for reaching out!

@dkreuer dkreuer added this to the 0.2.0 milestone Jan 12, 2024
@dkreuer
Copy link
Member

dkreuer commented Jan 12, 2024

@fliot @ianneub Does the example logging in #2 satisfy your need?

@fliot
Copy link

fliot commented Jan 15, 2024

Super !!!!!!!!!
Congrats.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants