Commit Graph

2903 Commits

Author SHA1 Message Date
Stephen Day
4118a256e9 Merge pull request #1234 from dmcgowan/update-logrus
update to github.com/sirupsen/logrus v1.0.0 [carry #1136]
2017-07-21 16:26:24 -07:00
Derek McGowan
1491293260
Update dependencies for logrus rename
Signed-off-by: Derek McGowan <derek@mcgstyle.net>
2017-07-21 16:14:03 -07:00
Andrew Pennebaker
1d2a079f08
update to github.com/sirupsen/logrus v1.0.0
Signed-off-by: Andrew Pennebaker <apennebaker@datapipe.com>
2017-07-21 15:39:14 -07:00
Stephen Day
dd7642fc1c Merge pull request #1196 from mlaventure/update-windows-runtime
Update windows runtime
2017-07-21 15:12:53 -07:00
Phil Estes
a2df6d1adc Merge pull request #1141 from ijc/rootfsPropagation
containerd-shim: Do not remount root MS_SLAVE
2017-07-21 16:18:41 -04:00
Derek McGowan
0f6959a2fc Merge pull request #1160 from darkowlzz/1082-snapshot-commit
cmd/ctr: add commit command to snapshot
2017-07-21 10:58:57 -07:00
Derek McGowan
a621185855 Merge pull request #1179 from AkihiroSuda/makefile-i
Makefile: `go build -i` -> `go build`
2017-07-21 10:02:22 -07:00
Kenfe-Mickael Laventure
aeab935572
Fix vet errors
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
eb4e0b5fb1
Add AppVeyor configuration
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
e3fcde6934
Fix deadlock in events service
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
5ea5fbdfc5
Fix deadlock in TestContainerExec if process.Wait() fails
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
d4e780d71f
Ensure tasks are started when running tests
This is needed on Windows since no process is actually running until
`Start()` is called, meaning no other operation by `Delete()` would
succeed.

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
3df07cbc88
Cancel io if task is deleted without being started
This prevent a deadlock on Windows since no process is actually running
until `Start()` is called.

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
8e12d1fcad
ctr: Allow deleting a container in the Created state
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
4d14bfd8ad
go-winio: Don't increment the wait count if the file is closing
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
7f786cf075
go-winio: Prevent Data Race when accessing closing
The race usually happens when `closeHandle()` and `prepareIo()` are called
concurrently; the former tries to set `closing` to `true` the latter tries
to read its value.

In order to avoid this issue, we added a lock around the variable.

Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
db1b0a2a5a
Update go-winio to v0.4.3
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
651aaff74e
Update integration test to support windows
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
79d04ded4e
Make integration a bit more verbose
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
b2d9db2e17
windows: Use runtime event topic constants
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
5c8e0efb63
windows: Add servicing code
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
4bb9ac2828
Sort ctr commands alphabetically
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
d0166c42ce
Register content command with ctr
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
d10c62d485
Wrap typeurl returned errors with the provided url/type
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
5fd004a1c0
Update vendoring
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
546f045128
Update errdefs.ErrInvalidArgument message
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
674b460d5a
Move typeurl registrations to runtime package
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:51 +02:00
Kenfe-Mickael Laventure
a4aaa09ccc
Update ctr so it works again on windows
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-21 18:19:48 +02:00
Kenfe-Mickael Laventure
61fbd2311c
windows: Refactor whole code
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-20 18:39:46 +02:00
Kenfe-Mickael Laventure
fc82e149ba
windows: Move runtime options out of the spec field
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-20 17:22:59 +02:00
Kenfe-Mickael Laventure
acf863a04e
windows: Rely on the OCI specs instead of custom type
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-20 17:22:59 +02:00
Kenfe-Mickael Laventure
bff040d087
windows: Ensure pids are not reused if active
Signed-off-by: Kenfe-Mickael Laventure <mickael.laventure@gmail.com>
2017-07-20 17:22:59 +02:00
Ian Campbell
d42cb88ba2 Loop umount'ing rootfs until there are no more mounts
This is simpler than trying to count how many successful mounts we made.

Signed-off-by: Ian Campbell <ian.campbell@docker.com>
2017-07-20 10:50:08 +01:00
Ian Campbell
d63d2ecf6c Simplify mount cleanup on failure by using defer
This avoids someone adding a new error path and forgetting to call the cleanup
function.

We prefer to use an explicit flag to gate the clean rather than relying on `err
!= nil` so we don't have to rely on people never accidentally shadowing the
`err` as seen by the closure.

Signed-off-by: Ian Campbell <ian.campbell@docker.com>
2017-07-20 10:50:08 +01:00
Ian Campbell
300f083127 Cleanup mounts if we fail to mount one element of rootfs
Signed-off-by: Ian Campbell <ian.campbell@docker.com>
2017-07-20 10:50:08 +01:00
Ian Campbell
8b365117a2 containerd-shim: Do not remount root MS_SLAVE
Mounting as MS_SLAVE here breaks use cases which want to use
rootPropagation=shared in order to expose mounts to the host (and other
containers binding the same subtree), mounting as e.g. MS_SHARED is pointless
in this context so just remove.

Having done this we also need to arrange to manually clean up the mounts on
delete, so do so.

Note that runc will also setup root as required by rootPropagation, defaulting
to MS_PRIVATE.

Fixes #1132.

Signed-off-by: Ian Campbell <ian.campbell@docker.com>
2017-07-20 10:50:08 +01:00
Stephen Day
0b3e572b85 Merge pull request #1221 from stevvooe/alpha1
containerd: prepare for v1.0.0-alpha1
2017-07-19 16:23:39 -07:00
Stephen J Day
6273d79c1a
containerd: prepare for v1.0.0-alpha1
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2017-07-19 16:14:51 -07:00
Stephen Day
28bb2b35b6 Merge pull request #1220 from stevvooe/release-target
Makefile: add release target
2017-07-19 16:13:22 -07:00
Stephen J Day
88656970c5
Makefile: add release target
Signed-off-by: Stephen J Day <stephen.day@docker.com>
2017-07-19 16:03:43 -07:00
Sunny Gogoi
912ddbae0f cmd/ctr: add commit command to snapshot
Signed-off-by: Sunny Gogoi <me@darkowlzz.space>
2017-07-20 04:17:15 +05:30
Stephen Day
28e8d95a64 Merge pull request #1210 from dmcgowan/use-forked-tar
Use forked archive/tar package for go 1.8 regression
2017-07-19 15:34:55 -07:00
Stephen Day
72c59aeb67 Merge pull request #1154 from darkowlzz/1082-snapshot-prepare
cmd/ctr: add mount subcommand to snapshot
2017-07-19 15:30:33 -07:00
Stephen Day
14e10c8724 Merge pull request #1214 from jovizhangwei/fix
Claim Go 1.8.x version requirement in BUILDING.md
2017-07-19 11:19:19 -07:00
Stephen Day
b5267baa88 Merge pull request #1216 from tklauser/prctl-x-sys-unix
Use Prctl() and associated constants from x/sys/unix
2017-07-19 11:11:40 -07:00
Phil Estes
834cafc2d6 Merge pull request #1206 from AkihiroSuda/improve-btrfs-error
btrfs: improve an error string
2017-07-19 09:56:58 -04:00
Phil Estes
70dc92f1a4 Merge pull request #1217 from fate-grand-order/fixed
correct some misspellings to make Go Report more happy
2017-07-19 09:48:12 -04:00
Phil Estes
0600753bd8 Merge pull request #1208 from dmcgowan/tar-test
archive: add link breakout checks and tests
2017-07-19 09:47:17 -04:00
Phil Estes
648f82e463 Merge pull request #1211 from stevvooe/no-build-proto
Makefile: no need to build protos binary
2017-07-19 09:44:41 -04:00
He Xiaoxi
b6dbbd337d Fix typo error in Protobuild.toml
Signed-off-by: He Xiaoxi <tossmilestone@gmail.com>
2017-07-19 20:28:33 +08:00