feat(docker): build centreon-collect docker image#2844
Conversation
|
Important Review skippedAuto reviews are limited based on label configuration. 🏷️ Required labels (at least one) (1)
Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Great job! No new security vulnerabilities introduced in this pull request |
…to init - Move inline Python heredoc from 45-plugin-watcher_background.sh into a standalone check_plugins.py (entrypoint dir is copied wholesale, no Dockerfile change needed) - Move apt-get update to 00-init.sh so package lists are refreshed once at startup, mirroring the same fix applied to the gorgone image Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add docker/poller/ with docker-compose.yml, .env.example and README - Add docker/README.md as the general image reference guide - Gitignore docker/**/.env to prevent committing credentials Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…reon-collect into fth-docker-collect
… work accordingly
… from poller compose
- Add USER centreon-gorgone to gorgone Dockerfile - Remove gosu from container.sh (no longer needed) - Add sudo apt-get update permission to gorgone sudoers - Fix 00-init.sh in both engine and gorgone to use sudo apt-get - Add one-liner poller deployment to docker README quickstart Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Mirror engine pattern: create sudoersCentreon with correct syntax centreon-gorgone ALL=(ALL) NOPASSWD: /usr/bin/apt, /usr/bin/apt-get Remove incorrect inline entry from centreon sudoers file
…e shadowing Runtime volume mounted on /var/lib/centreon-gorgone/ was masking entrypoint scripts at startup, causing old versions to persist. Move scripts to /usr/local/lib/centreon-gorgone/ (app code) and keep /var/lib/centreon-gorgone/ purely for runtime state (keys, history.sdb). Rename volume poller-gorgone-keys -> poller-gorgone-data to reflect scope.
…figs Config files deployed from central are owned by www-data:www-data 660 (produced by centreon-web / Apache). centreon-engine was not a member of www-data in the engine container, breaking config reload after push.
The COPY line for sudoersCentreon was lost in a7cc75c, causing sudo apt-get to prompt for a password instead of using NOPASSWD.
- Remove 31-centreon-api.yaml (unresolved API credentials, no web on poller) - Remove action module from generated poller config (already loaded via 39-action.yaml) - Set correct permissions on generated 40-gorgoned.yaml
retention.dat and status.dat persist via the poller-centlog volume. centengine.log and archives/ are truncated/cleared on each startup so they don't accumulate across restarts.
- centengine now runs as direct CMD (no more uvicorn/FastAPI wrapper) - gorgone systemctl uses grpcurl to call centengine gRPC API: - reload -> SignalProcess(RESTART) (config reload, equivalent to SIGHUP) - restart -> SignalProcess(SHUTDOWN) (Docker restart policy brings it back) - grpcurl v1.9.3 added to gorgone image with engine.proto/process_stat.proto - 05-engine-config.sh injects rpc_listen_address=0.0.0.0 at startup until Centreon web export includes it natively - Removes python venv pre-install from engine image (~30-40 MB saved)
python3-minimal on Debian does not include the standard library (json, etc.). Previously python3.11-venv pulled it in transitively; now python3 is explicit.
…tdout Use a FIFO at /var/log/centreon-engine/centengine.log so centengine logs flow directly to Docker stdout without accumulating on disk. 00-init.sh recreates the pipe on each start; 99-logs.sh forwards it via sed to docker logs with [ENGINE-LOG] prefix before exec-ing centengine. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
…ation Remove named pipe approach. centengine log routing to Docker stdout is configured from the Centreon web UI (log_v2_logger=file, log_file=/dev/stdout). 05-engine-config.sh only patches rpc_listen_address=0.0.0.0 at startup.

Description
feat(docker): build centreon-collect docker image