microcks / microcks/microcks-cli

Docker Hardened Images (dhi.io) as a new container image variant

Aperta
#298 0 commenti 2 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Lingua principale
Go
Stelle
52
Fork
68
Merge medio
6h 54m
PR unite (30g)
10

Descrizione

Reason/Context

Like discussed with @lbroudoux and @yada, the Microcks project broadly could benefit from the free DHI images: https://www.docker.com/blog/docker-hardened-images-for-every-developer/.

This will allow to improve the security posture of Microcks CLI's end users, and will also minize the surface of maintenance for the Microcks's Maintainers (CVEs noise in the Scout dashboard, continuous patching of unnecessary packages, etc.).

Description

The container image of the CLI could be optimized in terms of size, number of packages and number of CVEs. See my tests here: https://github.com/mathieu-benoit/microcks-cli/pull/1.

The goal is to provide a new -distroless variant, alongside the existing tags. The benefits of this new variant will allow to have the first tests with dhi.io for a Microcks project. It will allow to get an opt-in approach for the end users and not yet defaulting to it.

In the longer terms, if successful, we may want to reduce back the number of variant and defaulting the dhi.io image, but the proposition is to capture feedback and gain experience first.

Implementation ideas

File to update: https://github.com/microcks/microcks-cli/blob/master/build/Dockerfile:

  • FROM golang --> FROM dhi.io/golang
  • FROM registry.access.redhat.com/ubi9/ubi-minimal --> FROM dhi.io/static

The actual implementation is already in my fork there: https://github.com/mathieu-benoit/microcks-cli/pull/1, see there for more details about the implementation and the actual outcomes/benefits.

If accepted, just let me know and I'll port this PR officially here if this is ok?

tl,dr - With DHI it's:

  • 132 packages less
  • 150MB on disk less
  • 22 CVEs less
  • distroless (no unnecessary package manager, bash, curl, etc.)

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Direzione di ricerca

Inizia da build/Dockerfile e confrontalo con l’implementazione nella pull request del fork collegato. Verifica come vengono creati i tag delle immagini esistenti, quindi conferma che insieme a essi venga prodotta una variante distroless opt-in e che fornisca le riduzioni dichiarate relative a pacchetti, dimensioni e CVE.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
docker, go
Ambito
cli, devops
Tipo di issue
Funzionalità
Difficoltà
2/5
Tempo stimato
1-3 ore
Stato di attività
Ferma
Chiarezza
Specificata chiaramente
Idoneità per principianti
45/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.