github.com/drone/runner-go@v1.12.0/secret/secret.go (about) 1 // Copyright 2019 Drone.IO Inc. All rights reserved. 2 // Use of this source code is governed by the Polyform License 3 // that can be found in the LICENSE file. 4 5 // Package secret provides secrets to a pipeline. 6 package secret 7 8 import ( 9 "context" 10 11 "github.com/drone/drone-go/drone" 12 "github.com/drone/runner-go/manifest" 13 ) 14 15 // Request provides arguments for requesting a secret from 16 // a secret Provider. 17 type Request struct { 18 Name string 19 Repo *drone.Repo 20 Build *drone.Build 21 Conf *manifest.Manifest 22 } 23 24 // Provider is the interface that must be implemented by a 25 // secret provider. 26 type Provider interface { 27 // Find finds and returns a requested secret. 28 Find(context.Context, *Request) (*drone.Secret, error) 29 }