stackabletech / docker-images

Apache License 2.0
17 stars 2 forks source link

Build statsd_exporter from source #777

Closed dervoeti closed 1 month ago

dervoeti commented 1 month ago

Description

Fixes #776

This PR enables building statsd_exporter, which is used in our Airflow and Superset images, from source.

I moved the build process of statsd_exporter into its own image, similar to Vector, to reduce code duplication and improve caching (e.g. if it's built for Airflow the built statsd_exporter binary in the cache can be reused in the Superset build).

I spun up a local cluster with the new Airflow image and inspected the metrics container, it provides metrics on port 9102. I also scanned the new image and it contains less vulnerabilities (this removed 2 of 3 critical vulnerabilities plus a few others).

I built the Airflow 2.9.2 image with the changes and ran the integration tests locally, they all passed.

dervoeti commented 1 month ago

I also changed the package installation step to use heredoc

razvan commented 1 month ago

I also changed the package installation step to use heredoc

Don't want to be a nag... at this point you could also put everything in one RUN layer.

dervoeti commented 1 month ago

I also changed the package installation step to use heredoc

Don't want to be a nag... at this point you could also put everything in one RUN layer.

Oh right! Done.