@@ -78,6 +78,7 @@ type Driver struct {
78
78
backend backend.Backend
79
79
platformMC platforms.MatchComparer
80
80
encryptRecipients []string
81
+ withReferrer bool
81
82
}
82
83
83
84
func detectBuilderVersion (ctx context.Context , builder string ) string {
@@ -175,6 +176,11 @@ func New(cfg map[string]string, platformMC platforms.MatchComparer) (*Driver, er
175
176
return nil , errors .Wrap (err , "invalid oci_ref option" )
176
177
}
177
178
179
+ withReferrer , err := parseBool (cfg ["with_referrer" ])
180
+ if err != nil {
181
+ return nil , errors .Wrap (err , "invalid with_referrer option" )
182
+ }
183
+
178
184
encryptRecipients := []string {}
179
185
if cfg ["encrypt_recipients" ] != "" {
180
186
encryptRecipients = strings .Split (cfg ["encrypt_recipients" ], "," )
@@ -201,6 +207,7 @@ func New(cfg map[string]string, platformMC platforms.MatchComparer) (*Driver, er
201
207
backend : _backend ,
202
208
platformMC : platformMC ,
203
209
encryptRecipients : encryptRecipients ,
210
+ withReferrer : withReferrer ,
204
211
}, nil
205
212
}
206
213
@@ -263,6 +270,7 @@ func (d *Driver) convert(ctx context.Context, provider accelcontent.Provider, so
263
270
OCI : d .docker2oci ,
264
271
OCIRef : packOpt .OCIRef ,
265
272
EncryptRecipients : d .encryptRecipients ,
273
+ WithReferrer : d .withReferrer ,
266
274
}
267
275
convertHookFunc := func (
268
276
ctx context.Context , cs content.Store , orgDesc ocispec.Descriptor , newDesc * ocispec.Descriptor ,
0 commit comments