Skip to content

feat(docker): build centreon-collect docker image#2844

Draft
kduret wants to merge 156 commits into
developfrom
fth-docker-collect
Draft

feat(docker): build centreon-collect docker image#2844
kduret wants to merge 156 commits into
developfrom
fth-docker-collect

Conversation

@kduret

@kduret kduret commented Oct 9, 2025

Copy link
Copy Markdown
Contributor

Description

feat(docker): build centreon-collect docker image

@coderabbitai

coderabbitai Bot commented Oct 9, 2025

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are limited based on label configuration.

🏷️ Required labels (at least one) (1)
  • coderabbit

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: eb6c1b3b-6774-4d56-8964-8a05de88a8cf

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fth-docker-collect

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions

github-actions Bot commented Oct 9, 2025

Copy link
Copy Markdown

Logo
Checkmarx One – Scan Summary & Details95ebe18c-d227-4b70-b3ee-c761ad06fb7b

Great job! No new security vulnerabilities introduced in this pull request

Tpo76 and others added 4 commits March 24, 2026 18:24
…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>
Tpo76 and others added 24 commits March 31, 2026 10:00
- 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.
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.

4 participants