diff --git a/bitnami/prometheus/2/debian-11/Dockerfile b/bitnami/prometheus/2/debian-11/Dockerfile new file mode 100644 index 000000000000..6afc52c068cc --- /dev/null +++ b/bitnami/prometheus/2/debian-11/Dockerfile @@ -0,0 +1,33 @@ +FROM docker.io/bitnami/minideb:bullseye +LABEL maintainer "Bitnami " + +ENV HOME="/" \ + OS_ARCH="amd64" \ + OS_FLAVOUR="debian-11" \ + OS_NAME="linux" + +COPY prebuildfs / +# Install required system packages and dependencies +RUN install_packages ca-certificates curl gzip procps tar wget +RUN wget -nc -P /tmp/bitnami/pkg/cache/ https://downloads.bitnami.com/files/stacksmith/prometheus-2.36.0-0-linux-amd64-debian-11.tar.gz && \ + echo "67dbff6d3bbb1b5258629bdad84b8f90a88569573569e4413e282586a38fd7ee /tmp/bitnami/pkg/cache/prometheus-2.36.0-0-linux-amd64-debian-11.tar.gz" | sha256sum -c - && \ + tar -zxf /tmp/bitnami/pkg/cache/prometheus-2.36.0-0-linux-amd64-debian-11.tar.gz -P --transform 's|^[^/]*/files|/opt/bitnami|' --wildcards '*/files' && \ + rm -rf /tmp/bitnami/pkg/cache/prometheus-2.36.0-0-linux-amd64-debian-11.tar.gz +RUN apt-get update && apt-get upgrade -y && \ + rm -r /var/lib/apt/lists /var/cache/apt/archives +RUN chmod g+rwX /opt/bitnami +RUN ln -sf /opt/bitnami/prometheus/conf /etc/prometheus +RUN ln -sf /opt/bitnami/prometheus/data /prometheus +RUN chown -R 1001:1001 /opt/bitnami/prometheus + +RUN mkdir -p /opt/bitnami/prometheus/data/ && chmod g+rwX /opt/bitnami/prometheus/data/ +ENV APP_VERSION="2.36.0" \ + BITNAMI_APP_NAME="prometheus" \ + PATH="/opt/bitnami/prometheus/bin:$PATH" + +EXPOSE 9090 + +WORKDIR /opt/bitnami/prometheus +USER 1001 +ENTRYPOINT [ "/opt/bitnami/prometheus/bin/prometheus" ] +CMD [ "--config.file=/opt/bitnami/prometheus/conf/prometheus.yml", "--storage.tsdb.path=/opt/bitnami/prometheus/data", "--web.console.libraries=/opt/bitnami/prometheus/conf/console_libraries", "--web.console.templates=/opt/bitnami/prometheus/conf/consoles" ] diff --git a/bitnami/prometheus/2/debian-11/docker-compose.yml b/bitnami/prometheus/2/debian-11/docker-compose.yml new file mode 100644 index 000000000000..4013d6d6802e --- /dev/null +++ b/bitnami/prometheus/2/debian-11/docker-compose.yml @@ -0,0 +1,7 @@ +version: '2' + +services: + prometheus: + image: docker.io/bitnami/prometheus:2 + ports: + - '9090:9090' diff --git a/bitnami/prometheus/2/debian-11/prebuildfs/opt/bitnami/.bitnami_components.json b/bitnami/prometheus/2/debian-11/prebuildfs/opt/bitnami/.bitnami_components.json new file mode 100644 index 000000000000..3f2f24c7b7c7 --- /dev/null +++ b/bitnami/prometheus/2/debian-11/prebuildfs/opt/bitnami/.bitnami_components.json @@ -0,0 +1,9 @@ +{ + "prometheus": { + "arch": "amd64", + "digest": "67dbff6d3bbb1b5258629bdad84b8f90a88569573569e4413e282586a38fd7ee", + "distro": "debian-11", + "type": "NAMI", + "version": "2.36.0-0" + } +} \ No newline at end of file diff --git a/bitnami/prometheus/2/debian-11/prebuildfs/opt/bitnami/licenses/licenses.txt b/bitnami/prometheus/2/debian-11/prebuildfs/opt/bitnami/licenses/licenses.txt new file mode 100644 index 000000000000..c76ba31f3b8a --- /dev/null +++ b/bitnami/prometheus/2/debian-11/prebuildfs/opt/bitnami/licenses/licenses.txt @@ -0,0 +1,3 @@ +Bitnami containers ship with software bundles. You can find the licenses under: +/opt/bitnami/nami/COPYING +/opt/bitnami/[name-of-bundle]/licenses/[bundle-version].txt diff --git a/bitnami/prometheus/2/debian-11/prebuildfs/usr/sbin/install_packages b/bitnami/prometheus/2/debian-11/prebuildfs/usr/sbin/install_packages new file mode 100755 index 000000000000..c9577647443b --- /dev/null +++ b/bitnami/prometheus/2/debian-11/prebuildfs/usr/sbin/install_packages @@ -0,0 +1,24 @@ +#!/bin/sh +set -e +set -u +export DEBIAN_FRONTEND=noninteractive +n=0 +max=2 +until [ $n -gt $max ]; do + set +e + ( + apt-get update -qq && + apt-get install -y --no-install-recommends "$@" + ) + CODE=$? + set -e + if [ $CODE -eq 0 ]; then + break + fi + if [ $n -eq $max ]; then + exit $CODE + fi + echo "apt failed, retrying" + n=$(($n + 1)) +done +rm -r /var/lib/apt/lists /var/cache/apt/archives diff --git a/bitnami/prometheus/README.md b/bitnami/prometheus/README.md index 5cbae79dfff0..0e6525df0e14 100644 --- a/bitnami/prometheus/README.md +++ b/bitnami/prometheus/README.md @@ -32,7 +32,7 @@ Non-root container images add an extra layer of security and are generally recom Learn more about the Bitnami tagging policy and the difference between rolling tags and immutable tags [in our documentation page](https://docs.bitnami.com/tutorials/understand-rolling-tags-containers/). -* [`2`, `2-debian-10`, `2.36.0`, `2.36.0-debian-10-r6`, `latest` (2/debian-10/Dockerfile)](https://github.com/bitnami/bitnami-docker-prometheus/blob/2.36.0-debian-10-r6/2/debian-10/Dockerfile) +* [`2`, `2-debian-11`, `2.36.0`, `2.36.0-debian-11-r0`, `latest` (2/debian-11/Dockerfile)](https://github.com/bitnami/bitnami-docker-prometheus/blob/2.36.0-debian-11-r0/2/debian-11/Dockerfile) Subscribe to project updates by watching the [bitnami/prometheus GitHub repo](https://github.com/bitnami/bitnami-docker-prometheus). @@ -53,7 +53,7 @@ $ docker pull bitnami/prometheus:[TAG] If you wish, you can also build the image yourself. ```console -$ docker build -t bitnami/prometheus:latest 'https://github.com/bitnami/bitnami-docker-prometheus.git#master:2/debian-10' +$ docker build -t bitnami/prometheus:latest 'https://github.com/bitnami/bitnami-docker-prometheus.git#master:2/debian-11' ``` ## Persisting your database