From 1d10ca739f3599b9bd746783ad15c8f51ce9f75c Mon Sep 17 00:00:00 2001 From: cdoern Date: Fri, 25 Jun 2021 14:26:33 -0400 Subject: Created scp.go image_scp_test.go and podman-image-scp.1.md added functionality for image secure copying from local to remote. Also moved system connection add code around a bit so functions within that file can be used by scp. Signed-off-by: cdoern --- vendor/github.com/dtylman/scp/README.md | 42 +++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) create mode 100644 vendor/github.com/dtylman/scp/README.md (limited to 'vendor/github.com/dtylman/scp/README.md') diff --git a/vendor/github.com/dtylman/scp/README.md b/vendor/github.com/dtylman/scp/README.md new file mode 100644 index 000000000..48cfefe02 --- /dev/null +++ b/vendor/github.com/dtylman/scp/README.md @@ -0,0 +1,42 @@ +# scp + +[![Go Report Card](https://goreportcard.com/badge/github.com/dtylman/scp)](https://goreportcard.com/report/github.com/dtylman/scp) + +A Simple `go` SCP client library. + +## Usage + +```go +import ( + "github.com/dtylman/scp" + "golang.org/x/crypto/ssh" +) +``` + +## Sending Files + +Copies `/var/log/messages` to remote `/tmp/lala`: + +```go +var sc* ssh.Client +// establish ssh connection into sc here... +n,err:=scp.CopyTo(sc, "/var/log/messages", "/tmp/lala") +if err==nil{ + fmt.Printf("Sent %v bytes",n) +} +``` + +## Receiving Files + +Copies remote `/var/log/message` to local `/tmp/lala`: + +```go +var sc* ssh.Client +// establish ssh connection into sc here... +n,err:=scp.CopyFrom(sc, "/var/log/message", "/tmp/lala") +if err==nil{ + fmt.Printf("Sent %v bytes",n) +} +``` + + -- cgit v1.2.3-54-g00ecf