Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extend the parameters of 'images.load' and 'login' methods #434

Merged

Conversation

milanbalazs
Copy link
Contributor

The new parameters of login method based on SystemAuth docs:

  • auth: TBD description
  • identitytoken: IdentityToken is used to authenticate the user and get an access token for the registry.
  • registrytoken: RegistryToken is a bearer token to be sent to a registry
  • tls_verify: Whether to verify TLS certificates.

The new parameter of images.load method:

  • file_path: Path of the Tarball. If it's set then the load method opens the file and reads it as bytes. It means the method is able to handle file path as well, not only bytes. The scenarios when none of parameters or both of them are set are handled in the method.

Fix for:

- Handle the URL scheme based on TLS
- Since the 'auth' argument is not well documented in the podman
  swagger it will follow the same here until the swagger is better
  documented

Signed-off-by: Milan Balazs <[email protected]>
- Add tests for images.load
- Add validation of arguments via exceptions
- Split the load function so it can raise but can also keep the retun
  type without yielding

Signed-off-by: Milan Balazs <[email protected]>
@inknos
Copy link
Contributor

inknos commented Sep 26, 2024

/lgtm

@openshift-ci openshift-ci bot added the lgtm label Sep 26, 2024
@inknos inknos self-requested a review September 26, 2024 09:03
@rhatdan
Copy link
Member

rhatdan commented Sep 26, 2024

/approve

Copy link
Contributor

openshift-ci bot commented Sep 26, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: inknos, milanbalazs, rhatdan

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 1c8c5bc into containers:main Sep 26, 2024
16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants