Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
aledbf authored and csweichel committed Jul 8, 2024
1 parent 9e23bed commit 176377b
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions pkg/leeway/provenance.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import (
"io/fs"
"os"
"path/filepath"
"strconv"
"strings"
"time"

Expand Down Expand Up @@ -42,22 +41,6 @@ const (
ProvenanceBuilderID = "github.com/gitpod-io/leeway"
)

var (
// maxBundleEntrySize is the maximum size in bytes an attestation bundle entry may have.
// If we encounter a bundle entry lager than this size, the build will fail.
// Note: we'll allocate multiple buffers if this size, i.e. this size directly impacts
// the amount of memory required during a build (parralellBuildCount * maxBundleEntrySize).
maxBundleEntrySize = func() int {
env := os.Getenv("LEEWAY_MAX_PROVENANCE_BUNDLE_SIZE")
res, err := strconv.ParseInt(env, 10, 64)
if err != nil {
return 2 * 1024 * 1024
}

return int(res)
}()
)

// writeProvenance produces a provenanceWriter which ought to be used during package builds
func writeProvenance(p *Package, buildctx *buildContext, builddir string, subjects []in_toto.Subject, buildStarted time.Time) (err error) {
if !p.C.W.Provenance.Enabled {
Expand Down

0 comments on commit 176377b

Please sign in to comment.