Skip to content

Use a more secure base-image for the Solr Operator docker image #294

Closed

Description

@HoustonPutman

The security report for the Solr Operator Docker image on it's ArtifactHub page is not very good. This is due mostly to the fact that the base image contains multiple known vulnerabilities.

The current base image is gcr.io/distroless/base:debug-nonroot, and the vulnerabilities come from the fact that we are using the base image, not because it's a debug image. If we instead use gcr.io/distroless/static:debug-nonroot, these vulnerabilities go away.

The base image isn't the whole story. Some of the GoLang libraries that the Solr Operator depends on contain vulnerabilities as well, however removing those will require an upgrade of Kubernetes versions which we cannot currently do. Solving the base-image is the first, and larger, step.

Activity

  1. added this to the main (v0.4.0) milestone on Jul 21, 2021
  2. HoustonPutman commented on Jul 21, 2021

    @HoustonPutman
    ContributorAuthor

    The difference between distroless/base and distroless/static is mainly for the purpose of including libc for go programs that use cgo, such as through the net package.

    Since the Solr Operator is built with CGO_ENABLED=false, we do not need libc, so we should be find to base our image on distroless/static.

    Kubebuilder uses distroless/static by default, so we should be safe with DNS resolution and Certificates when communicating within Kubernetes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    securityTLS or Auth for Solr

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions