Skip to content
This repository was archived by the owner on Oct 10, 2020. It is now read-only.

Commit 30c9504

Browse files
giusepperh-atomic-bot
authored andcommitted
docker: support credentials for accessing the source registry
Signed-off-by: Giuseppe Scrivano <[email protected]> Closes: #1120 Approved by: ashcrow
1 parent 1c877c5 commit 30c9504

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

Atomic/backends/_docker.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,12 +338,13 @@ def pull_image(self, image, remote_image_obj, **kwargs):
338338
if '@sha256:' in image:
339339
image = image.replace("@sha256:", ":")
340340

341+
src_creds = kwargs.get('src_creds')
341342
insecure = True if util.is_insecure_registry(self.d.info()['RegistryConfig'], registry) else False
342343
trust = Trust()
343344
trust.discover_sigstore(fq_name)
344345
util.write_out("Pulling {} ...".format(fq_name))
345346
util.skopeo_copy("docker://{}".format(fq_name), image, debug=debug, insecure=insecure,
346-
policy_filename=trust.policy_filename)
347+
policy_filename=trust.policy_filename, src_creds=src_creds)
347348
return 0
348349

349350
def delete_container(self, container, force=False):

0 commit comments

Comments
 (0)