Skip to content

Commit 9f1e273

Browse files
committed
fix lint errors
I am planning on squashing this later. Signed-off-by: arewm <arewm@users.noreply.github.com> rh-pre-commit.version: 2.3.2 rh-pre-commit.check-secrets: ENABLED
1 parent c8481f3 commit 9f1e273

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

pkg/chains/storage/oci/legacy.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ func (b *Backend) uploadSignatureWithReferrers(ctx context.Context, format simpl
359359
}
360360

361361
// uploadAttestationWithReferrers uses cosign's OCI 1.1 experimental API for attestations
362-
func (b *Backend) uploadAttestationWithReferrers(ctx context.Context, attestation *intoto.Statement, signature string, storageOpts config.StorageOpts, remoteOpts ...remote.Option) error {
362+
func (b *Backend) uploadAttestationWithReferrers(ctx context.Context, attestation *intoto.Statement, signature string, _ config.StorageOpts, remoteOpts ...remote.Option) error {
363363
logger := logging.FromContext(ctx)
364364
if len(attestation.Subject) == 0 {
365365
return errors.New("no subjects in attestation")

pkg/chains/storage/oci/options.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ func (o *targetRepoOption) applySimpleStorer(s *SimpleStorer) error {
5959
}
6060

6161
// WithReferrersAPI configures the storers to use OCI 1.1 referrers API.
62+
//nolint:ireturn // returning interface is the intended pattern for options
6263
func WithReferrersAPI(enabled bool) Option {
6364
return &referrersAPIOption{
6465
enabled: enabled,

pkg/config/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ const (
180180
gcsBucketKey = "storage.gcs.bucket"
181181
ociRepositoryKey = "storage.oci.repository"
182182
ociRepositoryInsecureKey = "storage.oci.repository.insecure"
183-
ociReferrersAPIKey = "storage.oci.referrers-api"
183+
ociReferrersAPIKey = "storage.oci.referrers-api" //nolint:gosec // G101: This is a config key, not hardcoded credentials
184184
docDBUrlKey = "storage.docdb.url"
185185
docDBMongoServerURLKey = "storage.docdb.mongo-server-url"
186186
docDBMongoServerURLDirKey = "storage.docdb.mongo-server-url-dir"

0 commit comments

Comments
 (0)