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

volumes: Add support for volume import which allows importing contents of external tarballs into podman volumes. #11307

Merged

Conversation

flouthoc
Copy link
Collaborator

Following PR allows users to import contents of external tarball into podman via.

$ podman volume import <vol_name> <src-path>

or

$ cat file.tar | podman volume import <vol_name> - 

Note: Following PR is missing tests which will be added once this is merged #11290

@flouthoc
Copy link
Collaborator Author

Wait for tests till this is merged #11290

@flouthoc flouthoc changed the title volumes: Add support for volume import which allow simporting contents of external tarballs into podman volumes. volumes: Add support for volume import which allows importing contents of external tarballs into podman volumes. Aug 23, 2021
@flouthoc
Copy link
Collaborator Author

flouthoc commented Aug 23, 2021

@Luap99 @mheon tests are missing on this one till export is merged but other then that should be good for review.

@flouthoc flouthoc force-pushed the volume-import-external branch from 69b4057 to c3fbd41 Compare August 23, 2021 10:53
@flouthoc
Copy link
Collaborator Author

We import on mountPoint irrespective of whether volume is mounted or not unlike volume export since mountPoint is being used as source for containers if nothing is mounted.

PS: I am ok to make it analogous to how it is being done in export for unmounted volumes.

@flouthoc flouthoc force-pushed the volume-import-external branch 2 times, most recently from 740590f to a8c5f44 Compare August 23, 2021 12:15
@rhatdan
Copy link
Member

rhatdan commented Aug 23, 2021

Fix your whitespace.

@flouthoc flouthoc force-pushed the volume-import-external branch 3 times, most recently from f03b8d0 to c258c87 Compare August 23, 2021 13:35
@rhatdan
Copy link
Member

rhatdan commented Aug 23, 2021

Needs tests...

@flouthoc
Copy link
Collaborator Author

@rhatdan I am just waiting for #11290 to be merged as tests with export will be much easier to write. But can do without it as well.

@flouthoc flouthoc force-pushed the volume-import-external branch 4 times, most recently from d52f99c to c78f0ee Compare August 24, 2021 08:53
@flouthoc flouthoc requested a review from rhatdan August 24, 2021 10:33
@flouthoc
Copy link
Collaborator Author

@rhatdan added tests for following PR.

@rhatdan
Copy link
Member

rhatdan commented Aug 24, 2021

Could you update podman-volume-export man page to mention podman-volume-import?

@rhatdan
Copy link
Member

rhatdan commented Aug 24, 2021

Also add examples using stdout and stdin.

podman volume export myvol | podman volume import oldmyvol -

@flouthoc flouthoc force-pushed the volume-import-external branch 2 times, most recently from 02e14cd to 6509379 Compare August 24, 2021 19:32
@TomSweeneyRedHat
Copy link
Member

@flouthoc all kinds of tests unhappiness

@TomSweeneyRedHat
Copy link
Member

All kinds of red unhappy tests.

@flouthoc flouthoc force-pushed the volume-import-external branch from 6509379 to cc39122 Compare August 25, 2021 04:07
@flouthoc
Copy link
Collaborator Author

@rhatdan @TomSweeneyRedHat PTAL

@rhatdan
Copy link
Member

rhatdan commented Aug 25, 2021

LGTM

@@ -186,6 +186,22 @@ EOF
}


# Podman volume import test
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice touch!

@flouthoc flouthoc force-pushed the volume-import-external branch from 61278d5 to 1fdffec Compare August 26, 2021 07:50
…lume

Following feature makes sure that users can load contents of external
tarball into the podman volumes.

Signed-off-by: flouthoc <[email protected]>
@flouthoc flouthoc force-pushed the volume-import-external branch from 1fdffec to d550770 Compare August 26, 2021 08:44
@mheon
Copy link
Member

mheon commented Aug 26, 2021

LGTM

@flouthoc flouthoc requested a review from giuseppe August 26, 2021 13:26
@rhatdan
Copy link
Member

rhatdan commented Aug 26, 2021

/lgtm
/approve

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Aug 26, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Aug 26, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: flouthoc, 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-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 26, 2021
@openshift-merge-robot openshift-merge-robot merged commit cb23559 into containers:main Aug 26, 2021
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 22, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants