Skip to content

Conversation

@spencerugbo
Copy link
Contributor

@spencerugbo spencerugbo commented Nov 28, 2025

Proposed changes

Limit the number of access logs that Agent tails by default in order to reduce overhead. The limit can be configured in the agent conf as seen in the following example:

log:
  # set log level (error, warn, info, debug; default "info")
  level: info
  # set log path. if empty, don't log to file.
  path: /var/log/nginx-agent/

allowed_directories: 
    - /etc/nginx
    - /etc/app_protect
    - /usr/local/etc/nginx
    - /usr/share/nginx/modules
    - /var/run/nginx
    - /var/log/nginx

data_plane_config:
    nginx:
        # set the max access log files to be watched (default 10)
        max_access_log_files: 5

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING document
  • I have run make install-tools and have attached any dependency changes to this pull request
  • If applicable, I have added tests that prove my fix is effective or that my feature works
  • If applicable, I have checked that any relevant tests pass after adding my changes
  • If applicable, I have updated any relevant documentation (README.md)
  • If applicable, I have tested my cross-platform changes on Ubuntu 22, Redhat 8, SUSE 15 and FreeBSD 13

@spencerugbo spencerugbo self-assigned this Nov 28, 2025
@github-actions github-actions bot added the chore Pull requests for routine tasks label Nov 28, 2025
@codecov
Copy link

codecov bot commented Nov 28, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 85.29%. Comparing base (db165d2) to head (7e3379e).
⚠️ Report is 9 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1418      +/-   ##
==========================================
- Coverage   86.27%   85.29%   -0.98%     
==========================================
  Files         102      102              
  Lines       12622    12938     +316     
==========================================
+ Hits        10890    11036     +146     
- Misses       1253     1416     +163     
- Partials      479      486       +7     
Files with missing lines Coverage Δ
internal/config/config.go 87.44% <100.00%> (+0.14%) ⬆️
internal/config/defaults.go 100.00% <ø> (ø)
internal/config/flags.go 100.00% <ø> (ø)
internal/config/types.go 87.65% <ø> (ø)
internal/datasource/config/nginx_config_parser.go 78.85% <100.00%> (+0.16%) ⬆️

... and 16 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update db165d2...7e3379e. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@spencerugbo spencerugbo marked this pull request as ready for review December 5, 2025 17:05
@spencerugbo spencerugbo requested a review from a team as a code owner December 5, 2025 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore Pull requests for routine tasks

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants