From 4ee55240ecae0895b3af3bfb297fb82e18fff885 Mon Sep 17 00:00:00 2001 From: jabdoa2 Date: Wed, 7 Aug 2024 22:08:14 +0200 Subject: [PATCH 1/5] Add Labels to Docker Images As a user I want to know where stuff in my image came from. Those standardized tags allow automated tools to find the source code. For instance, this will allow renovate bot to show a changelog (based on the github releases) and provide a nice link to the repo. --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index dba2e12..aa8fc4e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -35,6 +35,10 @@ RUN ["chmod", "-R", "u=rwX,go=rX", "/rootfs"] FROM scratch +LABEL org.opencontainers.image.documentation='https://icinga.com/docs/icinga-db/latest/doc/01-About/' \ + org.opencontainers.image.source='https://github.com/Icinga/icingadb' \ + org.opencontainers.image.licenses='GPL-2.0+' + COPY --from=base /rootfs/ / COPY --from=base --chown=icingadb:icingadb /empty /etc/icingadb COPY --from=entrypoint /entrypoint/entrypoint /entrypoint From e5ce08f3ed86ad2c97e5bb0ae1974f7371d66929 Mon Sep 17 00:00:00 2001 From: jabdoa2 Date: Thu, 8 Aug 2024 17:31:48 +0200 Subject: [PATCH 2/5] Update Dockerfile Co-authored-by: alvar <8402811+oxzi@users.noreply.github.com> --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index aa8fc4e..6be3412 100644 --- a/Dockerfile +++ b/Dockerfile @@ -35,7 +35,7 @@ RUN ["chmod", "-R", "u=rwX,go=rX", "/rootfs"] FROM scratch -LABEL org.opencontainers.image.documentation='https://icinga.com/docs/icinga-db/latest/doc/01-About/' \ +LABEL org.opencontainers.image.documentation='https://icinga.com/docs/icinga-db' \ org.opencontainers.image.source='https://github.com/Icinga/icingadb' \ org.opencontainers.image.licenses='GPL-2.0+' From b0cdcce972a08ac54282cd5382d049a7b765106b Mon Sep 17 00:00:00 2001 From: jabdoa2 Date: Thu, 8 Aug 2024 17:39:30 +0200 Subject: [PATCH 3/5] Update Dockerfile Co-authored-by: alvar <8402811+oxzi@users.noreply.github.com> --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 6be3412..0d2f8bd 100644 --- a/Dockerfile +++ b/Dockerfile @@ -37,7 +37,7 @@ FROM scratch LABEL org.opencontainers.image.documentation='https://icinga.com/docs/icinga-db' \ org.opencontainers.image.source='https://github.com/Icinga/icingadb' \ - org.opencontainers.image.licenses='GPL-2.0+' + org.opencontainers.image.licenses='GPL-2.0-or-later' COPY --from=base /rootfs/ / COPY --from=base --chown=icingadb:icingadb /empty /etc/icingadb From 4c8aa1cfac064d8188b84916ff9af1f0420fef06 Mon Sep 17 00:00:00 2001 From: jabdoa2 Date: Thu, 8 Aug 2024 17:42:42 +0200 Subject: [PATCH 4/5] Add image title and vendor to image in Dockerfile --- Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 0d2f8bd..95561ea 100644 --- a/Dockerfile +++ b/Dockerfile @@ -37,7 +37,9 @@ FROM scratch LABEL org.opencontainers.image.documentation='https://icinga.com/docs/icinga-db' \ org.opencontainers.image.source='https://github.com/Icinga/icingadb' \ - org.opencontainers.image.licenses='GPL-2.0-or-later' + org.opencontainers.image.licenses='GPL-2.0-or-later' \ + org.opencontainers.image.title='Icinga DB' \ + org.opencontainers.image.vendor='Icinga GmbH' COPY --from=base /rootfs/ / COPY --from=base --chown=icingadb:icingadb /empty /etc/icingadb From 41b4ea30223e8010c4cde2fabaca1753b214f061 Mon Sep 17 00:00:00 2001 From: jabdoa2 Date: Thu, 8 Aug 2024 17:44:29 +0200 Subject: [PATCH 5/5] Add link to repo containing the Dockerfile --- Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/Dockerfile b/Dockerfile index 95561ea..2dc3065 100644 --- a/Dockerfile +++ b/Dockerfile @@ -37,6 +37,7 @@ FROM scratch LABEL org.opencontainers.image.documentation='https://icinga.com/docs/icinga-db' \ org.opencontainers.image.source='https://github.com/Icinga/icingadb' \ + org.opencontainers.image.url='https://github.com/Icinga/docker-icingadb' \ org.opencontainers.image.licenses='GPL-2.0-or-later' \ org.opencontainers.image.title='Icinga DB' \ org.opencontainers.image.vendor='Icinga GmbH'