mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
Revert "checkpoint: resolve symlink for external bind mount"
This reverts commit da22625f69
(PR 2902).
Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
This commit is contained in:
@@ -780,9 +780,6 @@ const descriptorsFilename = "descriptors.json"
|
||||
|
||||
func (c *linuxContainer) addCriuDumpMount(req *criurpc.CriuReq, m *configs.Mount) {
|
||||
mountDest := strings.TrimPrefix(m.Destination, c.config.Rootfs)
|
||||
if dest, err := securejoin.SecureJoin(c.config.Rootfs, mountDest); err == nil {
|
||||
mountDest = dest[len(c.config.Rootfs):]
|
||||
}
|
||||
extMnt := &criurpc.ExtMountMap{
|
||||
Key: proto.String(mountDest),
|
||||
Val: proto.String(mountDest),
|
||||
|
||||
@@ -126,18 +126,7 @@ function simple_cr() {
|
||||
done
|
||||
}
|
||||
|
||||
@test "checkpoint and restore" {
|
||||
simple_cr
|
||||
}
|
||||
|
||||
@test "checkpoint and restore (bind mount, destination is symlink)" {
|
||||
mkdir -p rootfs/real/conf
|
||||
ln -s /real/conf rootfs/conf
|
||||
update_config ' .mounts += [{
|
||||
source: ".",
|
||||
destination: "/conf",
|
||||
options: ["bind"]
|
||||
}]'
|
||||
@test "checkpoint and restore " {
|
||||
simple_cr
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user