Last active
October 17, 2016 19:40
-
-
Save codersquid/10c978e0f792f0e59290f0a93a11c3df to your computer and use it in GitHub Desktop.
quick script to troubleshoot what is going on with recursive push
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
set -ex | |
LXC=/home/sheila/gopath/bin/lxc | |
COUNT=${1:-5} | |
echo making $COUNT test files | |
rm -rf exampledir | |
mkdir exampledir | |
for i in $(seq $COUNT) | |
do | |
echo testing > exampledir/testfile$i | |
done | |
echo Launching container | |
NAME=$($LXC launch ubuntu:16.04 | grep Starting | awk '{print $2}') | |
if [ -z "$NAME" ]; then | |
echo Unable to create container. exiting... | |
exit 1 | |
fi | |
echo Created $NAME | |
echo pushing files | |
$LXC file push -r $(pwd) $NAME/tmp | |
echo listing remote files in /tmp | |
$LXC exec $NAME -- find /tmp | |
echo local files | |
tree $(pwd) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
» ./debug-launch 10 | |
+ LXC=/home/sheila/gopath/bin/lxc | |
+ COUNT=10 | |
+ echo making 10 test files | |
making 10 test files | |
+ rm -rf exampledir | |
+ mkdir exampledir | |
+ seq 10 | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo Launching container | |
Launching container | |
+ /home/sheila/gopath/bin/lxc launch ubuntu:16.04 | |
+ grep Starting | |
+ awk {print $2} | |
+ NAME=grateful-lioness | |
+ [ -z grateful-lioness ] | |
+ echo Created grateful-lioness | |
Created grateful-lioness | |
+ echo pushing files | |
pushing files | |
+ pwd | |
+ /home/sheila/gopath/bin/lxc file push -r /tmp/tmp.0mkJRggfBn grateful-lioness/tmp | |
(string) (len=4) "/tmp" | |
(*http.Request)(0xc8200f0540)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82009a780)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fblah), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc8200940d0)({ | |
file: (*os.file)(0xc8200dfc00)({ | |
fd: (int) 3, | |
name: (string) (len=24) "/tmp/tmp.0mkJRggfBn/blah", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200f0620)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82009aa80)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fdebug-launch), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0775" | |
} | |
}, | |
Body: (*os.File)(0xc820094100)({ | |
file: (*os.file)(0xc8201882c0)({ | |
fd: (int) 3, | |
name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/debug-launch", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200f0700)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82009ad80)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile1), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc820094120)({ | |
file: (*os.file)(0xc8201887e0)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile1", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201540e0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82013a400)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile10), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
} | |
}, | |
Body: (*os.File)(0xc82015e008)({ | |
file: (*os.file)(0xc820128960)({ | |
fd: (int) 3, | |
name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile10", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200f07e0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82009b080)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile2), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc820094138)({ | |
file: (*os.file)(0xc820188ca0)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile2", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201541c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82013a700)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile3), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc82015e020)({ | |
file: (*os.file)(0xc820128e20)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile3", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc820220000)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82021a080)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile4), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc82021e000)({ | |
file: (*os.file)(0xc82020e080)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile4", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8202200e0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82021a380)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile5), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
} | |
}, | |
Body: (*os.File)(0xc82021e018)({ | |
file: (*os.file)(0xc82020e560)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile5", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200161c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201b6380)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile6), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc82002e018)({ | |
file: (*os.file)(0xc82000e960)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile6", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8202201c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82021a680)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile7), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc82021e030)({ | |
file: (*os.file)(0xc82020ea20)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile7", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200162a0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201b6680)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile8), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc82002e030)({ | |
file: (*os.file)(0xc82000ee20)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile8", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201542a0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82013aa00)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile9), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
} | |
}, | |
Body: (*os.File)(0xc82015e030)({ | |
file: (*os.file)(0xc8201292a0)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile9", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc820016380)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201b6980)(http://unix.socket/1.0/containers/grateful-lioness/files?path=tmp%2Ftmp.0mkJRggfBn%2Ftoplevelfile), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc82002e048)({ | |
file: (*os.file)(0xc82000f3a0)({ | |
fd: (int) 3, | |
name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/toplevelfile", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
error: open: No such file or directory | |
errno: 2 | |
sheila@yagi /tmp/tmp.0mkJRggfBn » |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
» ./debug-launch 5 | |
+ LXC=/home/sheila/gopath/bin/lxc | |
+ COUNT=5 | |
+ echo making 5 test files | |
making 5 test files | |
+ rm -rf exampledir | |
+ mkdir exampledir | |
+ seq 5 | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo Launching container | |
Launching container | |
+ /home/sheila/gopath/bin/lxc launch ubuntu:16.04 | |
+ grep Starting | |
+ awk {print $2} | |
+ NAME=relative-tortoise | |
+ [ -z relative-tortoise ] | |
+ echo Created relative-tortoise | |
Created relative-tortoise | |
+ echo pushing files | |
pushing files | |
+ pwd | |
+ /home/sheila/gopath/bin/lxc file push -r /tmp/tmp.0mkJRggfBn relative-tortoise/tmp | |
(string) (len=4) "/tmp" | |
(*http.Request)(0xc8201660e0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82014c380)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fblah), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
} | |
}, | |
Body: (*os.File)(0xc820170010)({ | |
file: (*os.file)(0xc82013aaa0)({ | |
fd: (int) 3, | |
name: (string) (len=24) "/tmp/tmp.0mkJRggfBn/blah", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201cc000)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201c6080)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fdebug-launch), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0775" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
} | |
}, | |
Body: (*os.File)(0xc8201b4008)({ | |
file: (*os.file)(0xc8201b2120)({ | |
fd: (int) 3, | |
name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/debug-launch", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200161c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820178380)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile1), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc82002e018)({ | |
file: (*os.file)(0xc82000e980)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile1", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201661c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82014c680)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile2), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc820170038)({ | |
file: (*os.file)(0xc82013b040)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile2", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200162a0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820178680)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile3), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
} | |
}, | |
Body: (*os.File)(0xc82002e030)({ | |
file: (*os.file)(0xc82000ee40)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile3", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201662a0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82014c980)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile4), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc820170050)({ | |
file: (*os.file)(0xc82013b520)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile4", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8200f0540)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82009a800)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile5), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc8200940d0)({ | |
file: (*os.file)(0xc8200dfb80)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile5", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc820016380)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820178980)(http://unix.socket/1.0/containers/relative-tortoise/files?path=tmp%2Ftmp.0mkJRggfBn%2Ftoplevelfile), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc82002e048)({ | |
file: (*os.file)(0xc82000f3c0)({ | |
fd: (int) 3, | |
name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/toplevelfile", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
+ echo listing remote files in /tmp | |
listing remote files in /tmp | |
+ /home/sheila/gopath/bin/lxc exec relative-tortoise -- find /tmp | |
/tmp | |
/tmp/.Test-unix | |
/tmp/.font-unix | |
/tmp/.X11-unix | |
/tmp/.ICE-unix | |
/tmp/.XIM-unix | |
+ echo local files | |
local files | |
+ pwd | |
+ tree /tmp/tmp.0mkJRggfBn | |
/tmp/tmp.0mkJRggfBn | |
├── blah | |
├── debug-launch | |
├── exampledir | |
│ ├── testfile1 | |
│ ├── testfile2 | |
│ ├── testfile3 | |
│ ├── testfile4 | |
│ └── testfile5 | |
└── toplevelfile | |
1 directory, 8 files | |
sheila@yagi /tmp/tmp.0mkJRg |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
» ./debug-launch 5 | |
+ LXC=/home/sheila/gopath/bin/lxc | |
+ COUNT=5 | |
+ echo making 5 test files | |
making 5 test files | |
+ rm -rf exampledir | |
+ mkdir exampledir | |
+ seq 5 | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo testing | |
+ echo Launching container | |
Launching container | |
+ /home/sheila/gopath/bin/lxc launch ubuntu:16.04 | |
+ awk {print $2} | |
+ grep Starting | |
+ NAME=great-ant | |
+ [ -z great-ant ] | |
+ echo Created great-ant | |
Created great-ant | |
+ echo pushing files | |
pushing files | |
+ pwd | |
+ /home/sheila/gopath/bin/lxc file push -r /tmp/tmp.0mkJRggfBn great-ant/tmp | |
(string) (len=4) "/tmp" | |
(*http.Request)(0xc820016620)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc82007c780)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fblah), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
} | |
}, | |
Body: (*os.File)(0xc82002e0d8)({ | |
file: (*os.file)(0xc8200f6220)({ | |
fd: (int) 3, | |
name: (string) (len=24) "/tmp/tmp.0mkJRggfBn/blah", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201420e0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820128400)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fdebug-launch), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0775" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc820144008)({ | |
file: (*os.file)(0xc820116aa0)({ | |
fd: (int) 3, | |
name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/debug-launch", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201b6000)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201aa080)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile1), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
} | |
}, | |
Body: (*os.File)(0xc8201ae008)({ | |
file: (*os.file)(0xc8201a00e0)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile1", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201421c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820128700)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile2), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc820144020)({ | |
file: (*os.file)(0xc820116fe0)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile2", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201b60e0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201aa380)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile3), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc8201ae020)({ | |
file: (*os.file)(0xc8201a0640)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile3", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201422a0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820128a00)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile4), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc820144038)({ | |
file: (*os.file)(0xc820117520)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile4", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc8201b61c0)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc8201aa680)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile5), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
}, | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
} | |
}, | |
Body: (*os.File)(0xc8201ae038)({ | |
file: (*os.file)(0xc8201a0b80)({ | |
fd: (int) 3, | |
name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile5", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
(*http.Request)(0xc820142380)({ | |
Method: (string) (len=4) "POST", | |
URL: (*url.URL)(0xc820128d00)(http://unix.socket/1.0/containers/great-ant/files?path=tmp%2Ftmp.0mkJRggfBn%2Ftoplevelfile), | |
Proto: (string) (len=8) "HTTP/1.1", | |
ProtoMajor: (int) 1, | |
ProtoMinor: (int) 1, | |
Header: (http.Header) (len=5) { | |
(string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { | |
(string) (len=4) "0664" | |
}, | |
(string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { | |
(string) (len=4) "1000" | |
}, | |
(string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { | |
(string) (len=9) "LXD 2.4.1" | |
}, | |
(string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { | |
(string) (len=4) "file" | |
} | |
}, | |
Body: (*os.File)(0xc820144050)({ | |
file: (*os.file)(0xc820117b20)({ | |
fd: (int) 3, | |
name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/toplevelfile", | |
dirinfo: (*os.dirInfo)(<nil>) | |
}) | |
}), | |
ContentLength: (int64) 0, | |
TransferEncoding: ([]string) <nil>, | |
Close: (bool) false, | |
Host: (string) (len=11) "unix.socket", | |
Form: (url.Values) <nil>, | |
PostForm: (url.Values) <nil>, | |
MultipartForm: (*multipart.Form)(<nil>), | |
Trailer: (http.Header) <nil>, | |
RemoteAddr: (string) "", | |
RequestURI: (string) "", | |
TLS: (*tls.ConnectionState)(<nil>), | |
Cancel: (<-chan struct {}) <nil> | |
}) | |
+ echo listing remote files in /tmp | |
listing remote files in /tmp | |
+ /home/sheila/gopath/bin/lxc exec great-ant -- find /tmp | |
/tmp | |
/tmp/tmp.0mkJRggfBn | |
/tmp/tmp.0mkJRggfBn/debug-launch | |
/tmp/tmp.0mkJRggfBn/exampledir | |
/tmp/tmp.0mkJRggfBn/exampledir/testfile2 | |
/tmp/tmp.0mkJRggfBn/exampledir/testfile1 | |
/tmp/tmp.0mkJRggfBn/exampledir/testfile3 | |
/tmp/tmp.0mkJRggfBn/exampledir/testfile5 | |
/tmp/tmp.0mkJRggfBn/exampledir/testfile4 | |
/tmp/tmp.0mkJRggfBn/blah | |
/tmp/tmp.0mkJRggfBn/toplevelfile | |
+ echo local files | |
local files | |
+ pwd | |
+ tree /tmp/tmp.0mkJRggfBn | |
/tmp/tmp.0mkJRggfBn | |
├── blah | |
├── debug-launch | |
├── exampledir | |
│ ├── testfile1 | |
│ ├── testfile2 | |
│ ├── testfile3 | |
│ ├── testfile4 | |
│ └── testfile5 | |
└── toplevelfile | |
1 directory, 8 files | |
sheila@yag |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment