mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #20619 from Microsoft/jjh/useraccounts
Windows: Updates for virtual user account
This commit is contained in:
commit
5fdfb2985b
1 changed files with 12 additions and 2 deletions
|
@ -658,7 +658,12 @@ func (s *DockerSuite) TestRunExitCode(c *check.C) {
|
|||
func (s *DockerSuite) TestRunUserDefaults(c *check.C) {
|
||||
expected := "uid=0(root) gid=0(root)"
|
||||
if daemonPlatform == "windows" {
|
||||
expected = "uid=1000(SYSTEM) gid=1000(SYSTEM)"
|
||||
// TODO Windows: Remove this check once TP4 is no longer supported.
|
||||
if windowsDaemonKV < 14250 {
|
||||
expected = "uid=1000(SYSTEM) gid=1000(SYSTEM)"
|
||||
} else {
|
||||
expected = "uid=1000(ContainerAdministrator) gid=1000(ContainerAdministrator)"
|
||||
}
|
||||
}
|
||||
out, _ := dockerCmd(c, "run", "busybox", "id")
|
||||
if !strings.Contains(out, expected) {
|
||||
|
@ -1710,7 +1715,12 @@ func (s *DockerSuite) TestRunCleanupCmdOnEntrypoint(c *check.C) {
|
|||
out = strings.TrimSpace(out)
|
||||
expected := "root"
|
||||
if daemonPlatform == "windows" {
|
||||
expected = `nt authority\system`
|
||||
// TODO Windows: Remove this check once TP4 is no longer supported.
|
||||
if windowsDaemonKV < 14250 {
|
||||
expected = `nt authority\system`
|
||||
} else {
|
||||
expected = `user manager\containeradministrator`
|
||||
}
|
||||
}
|
||||
if out != expected {
|
||||
c.Fatalf("Expected output %s, got %q", expected, out)
|
||||
|
|
Loading…
Reference in a new issue