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

Support "podman-remote cp" #4207

Closed
sshnaidm opened this issue Oct 6, 2019 · 22 comments
Closed

Support "podman-remote cp" #4207

sshnaidm opened this issue Oct 6, 2019 · 22 comments
Assignees
Labels
In Progress This issue is actively being worked by the assignee, please do not work on this at this time. kind/feature Categorizes issue or PR as related to a new feature. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@sshnaidm
Copy link
Member

sshnaidm commented Oct 6, 2019

Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)

/kind feature

Description

Add support for podman-remote to copy files from/to containers.

Describe the results you expected:

podman-remote cp /local_path/file container:/path/file
podman-remote cp container:/path/file /local_path/file

Additional information you deem important (e.g. issue happens only occasionally):

It will unblock remote containers execution in ansible podman plugin: ansible/ansible#63166

@github-actions
Copy link

github-actions bot commented Nov 9, 2019

This issue had no activity for 30 days. In the absence of activity or the "do-not-close" label, the issue will be automatically closed within 7 days.

@rhatdan
Copy link
Member

rhatdan commented Nov 9, 2019

This is still being worked and definitely something we want.

@vrothberg
Copy link
Member

This is still being worked and definitely something we want.

@rhatdan, still valid with the new v2 API coming?

@rhatdan
Copy link
Member

rhatdan commented Feb 11, 2020

Well we want it in V2 API.

@vrothberg
Copy link
Member

Well we want it in V2 API.

Note that the request mentions varlink explicitly.

@sshnaidm
Copy link
Member Author

Well we want it in V2 API.

Note that the request mentions varlink explicitly.

I think you can easily remove "varlink" from the description. The main goal is to have it remotely, no matter with which API

@vrothberg vrothberg changed the title Support "podman-remote cp" - copying files from/to containers via varlink remotely Support "podman-remote cp" Feb 11, 2020
@vrothberg vrothberg assigned baude and unassigned QiWang19 Feb 11, 2020
@vrothberg
Copy link
Member

I think you can easily remove "varlink" from the description. The main goal is to have it remotely, no matter with which API

Perfect! I did that and assigned @baude who is the driving force behind the new v2 API.

@rhatdan
Copy link
Member

rhatdan commented Feb 18, 2020

Yes this will be done in V2.

@afbjorklund
Copy link
Contributor

I used the following workaround, for missing remote functionality:

podman cp /foo container:/bar --> podman-remote exec -i container tee /bar < /foo

Even if it is fixed in Podman 2.0, clients will be older 1.x for a while.

We will still use the regular "cp" command, when running locally.

@rhatdan
Copy link
Member

rhatdan commented Jun 9, 2020

This is still being worked.

@rhatdan
Copy link
Member

rhatdan commented Sep 10, 2020

@sshnaidm @afbjorklund @vrothberg @baude Where are we on this one? We now have API V2 and podman cp should be using it.

@afbjorklund
Copy link
Contributor

Here is what I get, with podman-remote 2.0.6/podman 2.0.5:

 podman-remote cp /tmp/foo focused_knuth:foo
Error: unrecognized command `podman-remote cp`
Try 'podman-remote --help' for more information.
 podman --remote cp /tmp/foo focused_knuth:foo
Error: unrecognized command `podman cp`
Try 'podman --help' for more information.

Installing latest/greatest podman 2.0.6 (from koji) didn't help...

@afbjorklund
Copy link
Contributor

afbjorklund commented Sep 10, 2020

There are some weird ABIMode and TunnelMode constants.

And the "cp" command only has the ABIMode, assume that is local ?

Tried master:

 ./bin/podman cp
Error: accepts 2 arg(s), received 0
 ./bin/podman-remote cp
Error: unrecognized command `podman-remote cp`
Try 'podman-remote --help' for more information.

@mheon
Copy link
Member

mheon commented Sep 10, 2020

@rhatdan I was in the early stages of implementing this one before we went bugs-only

@rhatdan
Copy link
Member

rhatdan commented Sep 11, 2020

Ok sorry I thought we were further along.

@github-actions
Copy link

A friendly reminder that this issue had no activity for 30 days.

@rhatdan
Copy link
Member

rhatdan commented Oct 21, 2020

@jwhonce I think we need you to handle this one.

@holser
Copy link

holser commented Dec 14, 2020

Hi,

It would be nice to get this feature done, allowing operators to build images using Dockerfiles from their workstations rather than jumping in to servers to build image. This feature will make podman more development friendly, IMHO

@vrothberg
Copy link
Member

Thanks for reaching out, @holser. I am currently working on it. It's only a matter of polishing a couple of things.

@vrothberg vrothberg assigned vrothberg and unassigned jwhonce Dec 14, 2020
@vrothberg vrothberg added In Progress This issue is actively being worked by the assignee, please do not work on this at this time. and removed stale-issue labels Dec 14, 2020
@vrothberg vrothberg mentioned this issue Dec 18, 2020
@vrothberg
Copy link
Member

The PR is merged, closing

@afbjorklund
Copy link
Contributor

afbjorklund commented Dec 18, 2020

Having limited success, but whatever.

 ./bin/podman-remote run -d busybox sleep 3600
ERRO[0000] The storage 'driver' option must be set in /etc/containers/storage.conf, guarantee proper operation. 
1e0db3943cd8d75fcfa1656afc847a232b687a02f3ae05f2b24a723bc0b07cf3
 ./bin/podman-remote cp /tmp/foo infallible_cannon:foo
ERRO[0000] The storage 'driver' option must be set in /etc/containers/storage.conf, guarantee proper operation. 
Error: "foo" could not be found on container infallible_cannon: 405 Method Not Allowed

Not sure where this 405 is coming from

EDIT: ah, never mind - it was still talking to the old version

(i.e. a 3.0.0-dev client talking to the old/regular 2.2.1 server)

@vrothberg
Copy link
Member

Glad it works for you, @afbjorklund 👍

@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
In Progress This issue is actively being worked by the assignee, please do not work on this at this time. kind/feature Categorizes issue or PR as related to a new feature. 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 a pull request may close this issue.

10 participants