Last active
October 17, 2016 19:40
Revisions
-
codersquid revised this gist
Oct 17, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -24,7 +24,7 @@ fi echo Created $NAME echo pushing files $LXC file push --debug -r $(pwd) $NAME/tmp echo listing remote files in /tmp $LXC exec $NAME -- find /tmp echo local files -
codersquid revised this gist
Oct 17, 2016 . 4 changed files with 894 additions and 572 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -19,20 +19,24 @@ making 10 test files + echo Launching container Launching container + /home/sheila/gopath/bin/lxc launch ubuntu:16.04 + + grep Starting awk {print $2} + NAME=cute-narwhal + [ -z cute-narwhal ] + echo Created cute-narwhal Created cute-narwhal + echo pushing files pushing files + pwd + /home/sheila/gopath/bin/lxc file push --debug -r /tmp/tmp.0mkJRggfBn cute-narwhal/tmp DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{"api_extensions":["storage_zfs_remove_snapshots","container_host_shutdown_timeout","container_syscall_filtering","auth_pki","container_last_used_at","etag","patch","usb_devices","https_allowed_credentials","image_compression_algorithm","directory_manipulation","container_cpu_time","storage_zfs_use_refquota","storage_lvm_mount_options","network","profile_usedby","container_push"],"api_status":"stable","api_version":"1.0","auth":"trusted","config":{"core.https_address":"[::]","images.auto_update_cached":"false","images.auto_update_interval":"24","images.remote_cache_expiry":"5","storage.zfs_pool_name":"lxd"},"environment":{"addresses":["10.0.3.1:8443","10.0.4.1:8443","192.168.122.1:8443","172.17.0.1:8443","192.168.1.192:8443","192.168.1.114:8443","10.172.65.12:8443","[2001:67c:1562:8007::aac:410c]:8443"],"architectures":["x86_64","i686"],"certificate":"-----BEGIN CERTIFICATE-----\n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\nQ2WTGQ==\n-----END CERTIFICATE-----\n","driver":"lxc","driver_version":"2.0.5","kernel":"Linux","kernel_architecture":"x86_64","kernel_version":"4.4.0-43-generic","server":"lxd","server_pid":2133,"server_version":"2.4.1","storage":"dir","storage_version":""},"public":false}} (string) (len=4) "/tmp" DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee540)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820098780)(http://unix.socket/1.0/containers/cute-narwhal/files?path=tmp%2Ftmp.0mkJRggfBn%2Fblah), Proto: (string) (len=8) "HTTP/1.1", ProtoMajor: (int) 1, ProtoMinor: (int) 1, @@ -53,8 +57,8 @@ pushing files (string) (len=4) "1000" } }, Body: (*os.File)(0xc8200920d0)({ file: (*os.file)(0xc8200ddc00)({ fd: (int) 3, name: (string) (len=24) "/tmp/tmp.0mkJRggfBn/blah", dirinfo: (*os.dirInfo)(<nil>) @@ -73,13 +77,21 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201321c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82012e400)(http://unix.socket/1.0/containers/cute-narwhal/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" }, @@ -88,16 +100,10 @@ pushing files }, (string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { (string) (len=9) "LXD 2.4.1" } }, Body: (*os.File)(0xc820168008)({ file: (*os.file)(0xc820120a80)({ fd: (int) 3, name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/debug-launch", dirinfo: (*os.dirInfo)(<nil>) @@ -116,19 +122,17 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201322a0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82012e700)(http://unix.socket/1.0/containers/cute-narwhal/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=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" }, @@ -137,10 +141,16 @@ pushing files }, (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)(0xc820168028)({ file: (*os.file)(0xc820120fa0)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile1", dirinfo: (*os.dirInfo)(<nil>) @@ -159,13 +169,21 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200161c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201c0380)(http://unix.socket/1.0/containers/cute-narwhal/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=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" }, @@ -174,16 +192,10 @@ pushing files }, (string) (len=9) "X-Lxd-Uid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" } }, Body: (*os.File)(0xc82002c010)({ file: (*os.file)(0xc82000e920)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile10", dirinfo: (*os.dirInfo)(<nil>) @@ -202,13 +214,21 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee620)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820098a80)(http://unix.socket/1.0/containers/cute-narwhal/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) "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" }, @@ -217,16 +237,10 @@ pushing files }, (string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { (string) (len=4) "file" } }, Body: (*os.File)(0xc820092100)({ file: (*os.file)(0xc82019e1e0)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile2", dirinfo: (*os.dirInfo)(<nil>) @@ -245,13 +259,18 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200162a0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201c0680)(http://unix.socket/1.0/containers/cute-narwhal/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-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" }, @@ -263,13 +282,10 @@ pushing files }, (string) (len=10) "User-Agent": ([]string) (len=1 cap=1) { (string) (len=9) "LXD 2.4.1" } }, Body: (*os.File)(0xc82002c028)({ file: (*os.file)(0xc82000ede0)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile3", dirinfo: (*os.dirInfo)(<nil>) @@ -288,9 +304,11 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee700)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820098d80)(http://unix.socket/1.0/containers/cute-narwhal/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile4), Proto: (string) (len=8) "HTTP/1.1", ProtoMajor: (int) 1, ProtoMinor: (int) 1, @@ -311,8 +329,8 @@ pushing files (string) (len=4) "1000" } }, Body: (*os.File)(0xc820092118)({ file: (*os.file)(0xc82019e6a0)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile4", dirinfo: (*os.dirInfo)(<nil>) @@ -331,13 +349,18 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820132380)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82012ea00)(http://unix.socket/1.0/containers/cute-narwhal/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) "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" }, @@ -349,13 +372,10 @@ pushing files }, (string) (len=10) "X-Lxd-Type": ([]string) (len=1 cap=1) { (string) (len=4) "file" } }, Body: (*os.File)(0xc820168040)({ file: (*os.file)(0xc820121460)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile5", dirinfo: (*os.dirInfo)(<nil>) @@ -374,13 +394,21 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee7e0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820099080)(http://unix.socket/1.0/containers/cute-narwhal/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=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" }, @@ -389,16 +417,10 @@ pushing files }, (string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { (string) (len=4) "0664" } }, Body: (*os.File)(0xc820092130)({ file: (*os.file)(0xc82019eb60)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile6", dirinfo: (*os.dirInfo)(<nil>) @@ -417,19 +439,15 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820132460)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82012ed00)(http://unix.socket/1.0/containers/cute-narwhal/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=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" }, @@ -438,10 +456,16 @@ pushing files }, (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)(0xc820168058)({ file: (*os.file)(0xc820121920)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile7", dirinfo: (*os.dirInfo)(<nil>) @@ -460,9 +484,11 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee8c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820099380)(http://unix.socket/1.0/containers/cute-narwhal/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile8), Proto: (string) (len=8) "HTTP/1.1", ProtoMajor: (int) 1, ProtoMinor: (int) 1, @@ -483,8 +509,8 @@ pushing files (string) (len=4) "1000" } }, Body: (*os.File)(0xc820092148)({ file: (*os.file)(0xc82019f020)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile8", dirinfo: (*os.dirInfo)(<nil>) @@ -503,16 +529,15 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820132540)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82012f000)(http://unix.socket/1.0/containers/cute-narwhal/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-Gid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" }, @@ -524,10 +549,13 @@ pushing files }, (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)(0xc820168070)({ file: (*os.file)(0xc820121de0)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile9", dirinfo: (*os.dirInfo)(<nil>) @@ -546,13 +574,21 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820132620)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82012f300)(http://unix.socket/1.0/containers/cute-narwhal/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=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" }, @@ -561,16 +597,10 @@ pushing files }, (string) (len=10) "X-Lxd-Mode": ([]string) (len=1 cap=1) { (string) (len=4) "0664" } }, Body: (*os.File)(0xc820168080)({ file: (*os.file)(0xc820234320)({ fd: (int) 3, name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/toplevelfile", dirinfo: (*os.dirInfo)(<nil>) @@ -589,6 +619,38 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:24:50] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} + echo listing remote files in /tmp listing remote files in /tmp + /home/sheila/gopath/bin/lxc exec cute-narwhal -- find /tmp /tmp /tmp/.Test-unix /tmp/.font-unix /tmp/.X11-unix /tmp/tmp.0mkJRggfBn /tmp/tmp.0mkJRggfBn/toplevelfile /tmp/.ICE-unix /tmp/.XIM-unix + echo local files local files + pwd + tree /tmp/tmp.0mkJRggfBn /tmp/tmp.0mkJRggfBn ├── blah ├── debug-launch ├── exampledir │ ├── testfile1 │ ├── testfile10 │ ├── testfile2 │ ├── testfile3 │ ├── testfile4 │ ├── testfile5 │ ├── testfile6 │ ├── testfile7 │ ├── testfile8 │ └── testfile9 └── toplevelfile 1 directory, 13 files 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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,636 @@ » ./debug-launch 20 + LXC=/home/sheila/gopath/bin/lxc + COUNT=20 + echo making 20 test files making 20 test files + rm -rf exampledir + mkdir exampledir + seq 20 + echo testing + echo testing + echo testing + echo testing + echo testing + echo testing + echo testing + echo testing + echo testing + echo testing + 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=allowing-chigger + [ -z allowing-chigger ] + echo Created allowing-chigger Created allowing-chigger + echo pushing files pushing files + pwd + /home/sheila/gopath/bin/lxc file push --debug -r /tmp/tmp.0mkJRggfBn allowing-chigger/tmp DBUG[10-17|14:28:30] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{"api_extensions":["storage_zfs_remove_snapshots","container_host_shutdown_timeout","container_syscall_filtering","auth_pki","container_last_used_at","etag","patch","usb_devices","https_allowed_credentials","image_compression_algorithm","directory_manipulation","container_cpu_time","storage_zfs_use_refquota","storage_lvm_mount_options","network","profile_usedby","container_push"],"api_status":"stable","api_version":"1.0","auth":"trusted","config":{"core.https_address":"[::]","images.auto_update_cached":"false","images.auto_update_interval":"24","images.remote_cache_expiry":"5","storage.zfs_pool_name":"lxd"},"environment":{"addresses":["10.0.3.1:8443","10.0.4.1:8443","192.168.122.1:8443","172.17.0.1:8443","192.168.1.192:8443","192.168.1.114:8443","10.172.65.12:8443","[2001:67c:1562:8007::aac:410c]:8443"],"architectures":["x86_64","i686"],"certificate":"-----BEGIN CERTIFICATE-----\n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\nQ2WTGQ==\n-----END CERTIFICATE-----\n","driver":"lxc","driver_version":"2.0.5","kernel":"Linux","kernel_architecture":"x86_64","kernel_version":"4.4.0-43-generic","server":"lxd","server_pid":2133,"server_version":"2.4.1","storage":"dir","storage_version":""},"public":false}} (string) (len=4) "/tmp" DBUG[10-17|14:28:30] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820178000)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82016a080)(http://unix.socket/1.0/containers/allowing-chigger/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)(0xc820170008)({ file: (*os.file)(0xc82015e1e0)({ 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> }) DBUG[10-17|14:28:30] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201be000)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201b6080)(http://unix.socket/1.0/containers/allowing-chigger/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)(0xc8201bc000)({ file: (*os.file)(0xc8201201c0)({ 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> }) DBUG[10-17|14:28:30] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200160e0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201e4100)(http://unix.socket/1.0/containers/allowing-chigger/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) "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)(0xc82002c010)({ file: (*os.file)(0xc82000e720)({ 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201be0e0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201b6200)(http://unix.socket/1.0/containers/allowing-chigger/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) "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)(0xc8201bc010)({ file: (*os.file)(0xc8201205e0)({ 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200161c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201e4400)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile11), 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)(0xc82002c028)({ file: (*os.file)(0xc82000ebe0)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile11", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201be1c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201b6500)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile12), 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)(0xc8201bc028)({ file: (*os.file)(0xc820120aa0)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile12", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200162a0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201e4700)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile13), 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)(0xc82002c040)({ file: (*os.file)(0xc82000f0a0)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile13", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee7e0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820098d80)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile14), 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)(0xc8200920d8)({ file: (*os.file)(0xc82014e5a0)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile14", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820016380)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201e4a00)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile15), 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)(0xc82002c058)({ file: (*os.file)(0xc82000f560)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile15", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee8c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820099080)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile16), 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)(0xc8200920f0)({ file: (*os.file)(0xc82014ea60)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile16", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201be2a0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201b6800)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile17), 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)(0xc8201bc040)({ file: (*os.file)(0xc820120f60)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile17", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820016460)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc8201e4d00)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile18), 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)(0xc82002c070)({ file: (*os.file)(0xc82000fa20)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile18", 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> }) DBUG[10-17|14:28:31] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200ee9a0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820099380)(http://unix.socket/1.0/containers/allowing-chigger/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile19), 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)(0xc820092108)({ file: (*os.file)(0xc82014ef20)({ fd: (int) 3, name: (string) (len=41) "/tmp/tmp.0mkJRggfBn/exampledir/testfile19", 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> }) DBUG[10-17|14:28:31] Raw response: {"error":"open: No such file or directory\nerrno: 2","error_code":500,"type":"error"} error: open: No such file or directory errno: 2 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 charactersOriginal file line number Diff line number Diff line change @@ -1,397 +0,0 @@ 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 charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,4 @@ » ./debug-launch 5 + LXC=/home/sheila/gopath/bin/lxc + COUNT=5 + echo making 5 test files @@ -13,25 +13,32 @@ making 5 test files + echo testing + echo Launching container Launching container + grep Starting + awk {print $2} + /home/sheila/gopath/bin/lxc launch ubuntu:16.04 + NAME=key-hornet + [ -z key-hornet ] + echo Created key-hornet Created key-hornet + echo pushing files pushing files + pwd + /home/sheila/gopath/bin/lxc file push --debug -r /tmp/tmp.0mkJRggfBn key-hornet/tmp DBUG[10-17|14:26:10] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{"api_extensions":["storage_zfs_remove_snapshots","container_host_shutdown_timeout","container_syscall_filtering","auth_pki","container_last_used_at","etag","patch","usb_devices","https_allowed_credentials","image_compression_algorithm","directory_manipulation","container_cpu_time","storage_zfs_use_refquota","storage_lvm_mount_options","network","profile_usedby","container_push"],"api_status":"stable","api_version":"1.0","auth":"trusted","config":{"core.https_address":"[::]","images.auto_update_cached":"false","images.auto_update_interval":"24","images.remote_cache_expiry":"5","storage.zfs_pool_name":"lxd"},"environment":{"addresses":["10.0.3.1:8443","10.0.4.1:8443","192.168.122.1:8443","172.17.0.1:8443","192.168.1.192:8443","192.168.1.114:8443","10.172.65.12:8443","[2001:67c:1562:8007::aac:410c]:8443"],"architectures":["x86_64","i686"],"certificate":"-----BEGIN CERTIFICATE-----\nMIIGADCCA+igAwIBAgIQKelvtSQ0eHw1IvRAI9mIeDANBgkqhkiG9w0BAQsFADAy\nMRwwGgYDVQQKExNsaW51eGNvbnRhaW5lcnMub3JnMRIwEAYDVQQDDAlyb290QHlh\nZ2kwHhcNMTYwNDE5MjI0MzQ1WhcNMjYwNDE3MjI0MzQ1WjAyMRwwGgYDVQQKExNs\naW51eGNvbnRhaW5lcnMub3JnMRIwEAYDVQQDDAlyb290QHlhZ2kwggIiMA0GCSqG\nSIb3DQEBAQUAA4ICDwAwggIKAoICAQDLJlF86vOVeOGI/vZYagKCZsWtebjnoLSz\nzrN3zm6FDKLIVuJfi+BMLbARzg2Lrh1FFFtWpM2GF3QhOOnC19+AXVmXCJZo4mKO\nljSaHyzZXw2EFpkwoReon3gq0VZC6XI6Y5ybAIIBhvyieh0L4gxVvKHNRSm/ydn0\nmMxxHlPTu8niZ3F0QxSaNVHPtb68yJOo4pIm3LEfxuyjo7U3eiEr9gD4O4hQ/BMa\nQSKDV8fBbBt+wzBYkAkFf5SLKxKyeFB8XrmDQgJ2FEtsjxtf5IsGltJ2cBN9o67n\nH0OHWXICgTZOr9I5ys5p6n6c/2WFeLqQwGv6eLNsfEV/zJUzENtax0sv5ECsdPxP\nRGSDVxUwpboIxFWPzpZyL2fn2AC0ICqUF5r96SHWOYV7vpemQAgMYJKyfsKhWZOk\n68apd4hmmiC5KxXSnKVjgLn39szKgVBIqXFnlXD7DBv74JfpOJBe5jRPHUB2g5+J\nSM1Ka9b9bqh8U2FiPitwNAwdsRBGFLOt6BbIcbprrkQ+aTL43dlYLpvUyvzvh3TJ\ntGAhUBbvQ0kAiRGiEBrJ71z2QyfQNO034gTyC0SCXHGcsNDXk3/C3UjkGdmVdhwy\n8YKjQmrM4aP7Kw0olysfmSfLhxWloqQ1e8O3VQ+Efza+W4Y5QEbEJFsFeyz3Kjvk\n0PcoRYQVawIDAQABo4IBEDCCAQwwDgYDVR0PAQH/BAQDAgWgMBMGA1UdJQQMMAoG\nCCsGAQUFBwMBMAwGA1UdEwEB/wQCMAAwgdYGA1UdEQSBzjCBy4IEeWFnaYILMTAu\nMC4zLjEvMjSCHGZlODA6OjZjMTM6MzdmZjpmZTgyOmNhZWUvNjSCEDE5Mi4xNjgu\nMS4xMTcvMjSCHGZlODA6OjIyMTY6ZDhmZjpmZWNlOjY2YjkvNjSCDTE3Mi4xNy4w\nLjEvMTaCDzEwLjE3Mi42NS4xMi8xOIIfMjAwMTo2N2M6MTU2Mjo4MDA3OjphYWM6\nNDEwYy82NIIbZmU4MDo6YzFjOmZlZmY6ZmUxMzo2ZjFlLzY0ggpmZTgwOjoxLzY0\nMA0GCSqGSIb3DQEBCwUAA4ICAQBkA2lDOSWIpPsIAcBpG+mCCOjdvaxVZYCOQH8T\nuV0Ung4EN24+8hWP0JEGxbWBcIqPevCMyKjg2PgWCGedJfQjYdpl1JjZa/662iSm\nhPdLSP+ZItfS5HQllYvm+NanlV5XAlM1tTueSzQ7JIrhFuAHeRbte5st7LlVfACj\nDcqjpUKr4bgGKuhtBwBQYX8+mYx4IdTEIA0ebMureokz4roEMBFnXIDZAE0Udl/8\npXIVSNMWoyNyTAtSmrMQsXaHbWJbtFfsYxKiMOc8qPc6Lltj16s0ZsPLHRnERirz\nIS1DFAGmwSkjDSPeoWi2xbEDKCiLqUz3gJnUFlvMwQMMEKAnd/3Ca5mqaWhi8cMj\nqDi/5KpoA00vSrrYV/3eQhqzDqlfhbuzxJY8DE/Fbq2TdsOrYcP1E8mgdqYUW8xA\nHlRGmKIZuKvtMjp211Za8DvRjzcLnkstmsQEwy69kZwW9CPjs+eGh7xFzmfYtcae\nYGpWOzsBDi/HNSmCkJNAg+zZyEtdRLEa8k4Ixx1hEElarXEBGc5lxVxr/5unQ65I\nHxyNFpiAKdu6XnjO0DmjBztT2h4I8xWfv6g3tyOPSdGHK0VJ3h9vrfOaFZek1i9i\nhiirw+hmwnaEp92dC6QMA88rr5NeV9+yuwLgxkpMxHQmjcPIUF8HTEm002lTKKGC\nQ2WTGQ==\n-----END CERTIFICATE-----\n","driver":"lxc","driver_version":"2.0.5","kernel":"Linux","kernel_architecture":"x86_64","kernel_version":"4.4.0-43-generic","server":"lxd","server_pid":2133,"server_version":"2.4.1","storage":"dir","storage_version":""},"public":false}} (string) (len=4) "/tmp" DBUG[10-17|14:26:10] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc82017e000)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820170080)(http://unix.socket/1.0/containers/key-hornet/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" }, @@ -43,13 +50,10 @@ pushing files }, (string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" } }, Body: (*os.File)(0xc820176008)({ file: (*os.file)(0xc82010a220)({ fd: (int) 3, name: (string) (len=24) "/tmp/tmp.0mkJRggfBn/blah", dirinfo: (*os.dirInfo)(<nil>) @@ -68,19 +72,15 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8201341c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820130400)(http://unix.socket/1.0/containers/key-hornet/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-Mode": ([]string) (len=1 cap=1) { (string) (len=4) "0775" }, @@ -89,10 +89,16 @@ pushing files }, (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)(0xc820162008)({ file: (*os.file)(0xc820122b00)({ fd: (int) 3, name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/debug-launch", dirinfo: (*os.dirInfo)(<nil>) @@ -111,13 +117,20 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc820016700)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82007ca00)(http://unix.socket/1.0/containers/key-hornet/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) "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" }, @@ -129,13 +142,10 @@ pushing files }, (string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" } }, Body: (*os.File)(0xc82002c0e8)({ file: (*os.file)(0xc8200f6440)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile1", dirinfo: (*os.dirInfo)(<nil>) @@ -154,16 +164,15 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200167e0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82007cd00)(http://unix.socket/1.0/containers/key-hornet/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) "X-Lxd-Type": ([]string) (len=1 cap=1) { (string) (len=4) "file" }, @@ -175,10 +184,13 @@ pushing files }, (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)(0xc82002c0f8)({ file: (*os.file)(0xc8200f6940)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile2", dirinfo: (*os.dirInfo)(<nil>) @@ -197,9 +209,11 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc82021c000)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820218080)(http://unix.socket/1.0/containers/key-hornet/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile3), Proto: (string) (len=8) "HTTP/1.1", ProtoMajor: (int) 1, ProtoMinor: (int) 1, @@ -220,8 +234,8 @@ pushing files (string) (len=4) "1000" } }, Body: (*os.File)(0xc8201f8008)({ file: (*os.file)(0xc8201f60e0)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile3", dirinfo: (*os.dirInfo)(<nil>) @@ -240,13 +254,21 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200168c0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82007d000)(http://unix.socket/1.0/containers/key-hornet/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" }, @@ -255,16 +277,10 @@ pushing files }, (string) (len=9) "X-Lxd-Gid": ([]string) (len=1 cap=1) { (string) (len=4) "1000" } }, Body: (*os.File)(0xc82002c110)({ file: (*os.file)(0xc8200f6e80)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile4", dirinfo: (*os.dirInfo)(<nil>) @@ -283,9 +299,11 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc82021c0e0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc820218380)(http://unix.socket/1.0/containers/key-hornet/files?path=tmp%2Ftmp.0mkJRggfBn%2Fexampledir%2Ftestfile5), Proto: (string) (len=8) "HTTP/1.1", ProtoMajor: (int) 1, ProtoMinor: (int) 1, @@ -306,8 +324,8 @@ pushing files (string) (len=4) "1000" } }, Body: (*os.File)(0xc8201f8020)({ file: (*os.file)(0xc8201f6620)({ fd: (int) 3, name: (string) (len=40) "/tmp/tmp.0mkJRggfBn/exampledir/testfile5", dirinfo: (*os.dirInfo)(<nil>) @@ -326,9 +344,11 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} (*http.Request)(0xc8200169a0)({ Method: (string) (len=4) "POST", URL: (*url.URL)(0xc82007d300)(http://unix.socket/1.0/containers/key-hornet/files?path=tmp%2Ftmp.0mkJRggfBn%2Ftoplevelfile), Proto: (string) (len=8) "HTTP/1.1", ProtoMajor: (int) 1, ProtoMinor: (int) 1, @@ -349,8 +369,8 @@ pushing files (string) (len=4) "file" } }, Body: (*os.File)(0xc82002c128)({ file: (*os.file)(0xc8200f7480)({ fd: (int) 3, name: (string) (len=32) "/tmp/tmp.0mkJRggfBn/toplevelfile", dirinfo: (*os.dirInfo)(<nil>) @@ -369,9 +389,11 @@ pushing files TLS: (*tls.ConnectionState)(<nil>), Cancel: (<-chan struct {}) <nil> }) DBUG[10-17|14:26:11] Raw response: {"type":"sync","status":"Success","status_code":200,"metadata":{}} + echo listing remote files in /tmp listing remote files in /tmp + /home/sheila/gopath/bin/lxc exec key-hornet -- find /tmp /tmp /tmp/tmp.0mkJRggfBn /tmp/tmp.0mkJRggfBn/debug-launch @@ -399,4 +421,3 @@ local files └── toplevelfile 1 directory, 8 files -
codersquid revised this gist
Oct 17, 2016 . 4 changed files with 1393 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,594 @@ » ./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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,397 @@ » ./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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,402 @@ » ./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 Binary file not shown. -
codersquid created this gist
Oct 17, 2016 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,31 @@ #!/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)