danihodovic / celery-exporter

A Prometheus exporter for Celery metrics
MIT License
377 stars 83 forks source link

Added kombu.transport.pyamqp import to pyinstaller #271

Closed chripf closed 4 months ago

chripf commented 8 months ago

This is required for work with rabbitmq. Should fix #119 - regarding the last comments.

CFarcy commented 5 months ago

Any news on this PR being merged ?

Legrems commented 4 months ago

Dump? Still got the issue when using the executable alone :)

danihodovic commented 4 months ago

@CFarcy and @Legrems can you check out this branch and confirm that it works? Once you do I'll merge the PR.

Sorry about the delay, I was traveling through the jungle

CFarcy commented 4 months ago

Thanks for your reply @danihodovic , I hope you had a good time in the jungle :)

There is a typo in the Dockerfile.pyinstaller (missing space before \). I proposed a change for it.

Once the typo fixed, it seems to works (at least it run with no error).

Here is what I did to test it:

docker build . -t celery-exporter-builder -f Dockerfile.pyinstaller --build-arg PYTHON_VERSION=$(cat .python-version)
container=$(docker run --rm -d celery-exporter-builder sleep 5) && docker cp $container:/app/dist/celery-exporter ./celery-exporter
./celery-exporter --broker-url=amqp://localhost:5672

Then the metrics are available on localhost:9808 image

danihodovic commented 4 months ago

Released as v0.10.4 here https://github.com/danihodovic/celery-exporter/releases/tag/v0.10.4.

Thank you