Skip to content

Proposal to simplify and reduce the scope of sigstore/scaffolding #1833

@cmurphy

Description

@cmurphy

Objectives

  1. Reduce the number of binaries and images that need to be maintained.
  2. Eliminate complex code that is never used in production.
  3. Make the setup Github action (Kubernetes-based Sigstore) as lean as possible.

Proposed Changes

Deprecate and remove the createcerts command.

Why

  1. This is not used in production (for the Sigstore organization).
  2. Its objective - to automatically create the signing key and certificate for the Fulcio CA when using the fileca certificate authority mode - is easily accomplished with a few lines of shell using the openssl command and using the results to create Kubernetes Secrets.
  3. Since we only use the fileca mode for development and testing, generating these secrets securely is not a concern for our purposes.
  4. Creating the secret internally as a Kubernetes process necessitates that clients that require the root CA, such as the CT log, retrieve it from Fulcio’s rootCert HTTP endpoint. We don’t want to continue to encourage this practice, preferring instead to generate keys externally and distribute them in a secure manner, such as via TUF.

How

  1. Update the hack/setup-scaffolding.sh and hack/setup-scaffolding-form-release.sh scripts to generate the private key and self-signed CA and inject them as Secrets in the cluster for Fulcio. Change CTLog to accept a root PEM directly instead of fetching it from the rootCerts API.
  2. Change the default value of createcerts.enabled from true to false in the Fulcio Helm chart, and deprecate its usage.

Deprecate and remove rekor-createsecret and createcertchain

Why

For the same reasons as above - remove the dependency on a service's public endpoint and use an out-of-band mechanism to securely distribute key material instead.

Remove Trillian manifests

Why

There are Tessera-based replacements for the Trillian log server backend. The complexity of maintaining a relational database and multiple Trillian scripts for preparing and tracking the state of the tree is unnecessarily burdensome.

How

  1. Change the ct_server image to TesseraCT (already part of Deployment of tile-based CT log rekor-tiles#73).
    a. This removes the use of createctconfig from Scaffolding and removes the use of createtree as a dependency of the CT log.
    b. Future: deprecate the ctlog Helm chart entirely once TesseraCT is well used in production.
  2. Change the Rekor service to Rekor v2.
    a. This fully removes the use of createtree from the Scaffolding setup scripts.
    b. Enables removing all Trillian Kubernetes manifests.
    c. Future: deprecate the rekor Helm chart entirely.

Move utility commands to better locations

Why

Scaffolding has become a grab-bag of tools that have no better home. We need to slim down Scaffolding to fulfill its primary purpose, which is automating Kubernetes deployments with minimal manual intervention. The only Go commands that should live in Scaffolding should be those that are used as images in Jobs managed by helm-charts.

How

  1. Move create-tink-keyset to sigstore/sigstore (public) or to sigstore/public-good-instance (private). This command is not used in helm charts, it is run externally before deployment.

  2. Move prober to sigstore/sigstore-probers.

  3. Deprecate (do not remove):

    • cloudsqlproxy (Trillian)
    • createcerts (Fulcio)
    • createctconfig (CTLog/ct_server)
    • rekor-createsecret (Rekor v1)
    • createcertchain (TSA)
    • createdb (Trillian)
    • createtree (Trillian)
    • updatetree (Trillian)
  4. Simplify/rewrite or move test-only commands (exact work TBD)

    • managectroots
    • verifyfulcio
    • getoidctoken

Replace all ko-based Kubernetes manifests with helm-charts

Why

  1. The Kubernetes manifests in Scaffolding are not used in production and diverge heavily from the configuration that is used in production.
  2. The charts in helm-charts have no functional testing and are only ever “tested” in live environments.
  3. The burden of maintaining two separate Kubernetes configuration repositories is unnecessarily high.

How

The exact manner of building images with ko and then injecting them into helm-charts still needs further exploration, I’m not sure if we’ll still be able to use ko apply or ko resolve for this.

Comments welcome

Is Scaffolding being used in a way beyond 1) CI testing and 2) glue jobs for helm-charts that I'm not aware of and that these changes would adversely affect?

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions