Skip to content

Commit 6ef107e

Browse files
authored
Revert "Add docker rootless support for macOS and desktop for Linux (#6907)" (#7015)
This reverts commit 0bf52a9.
1 parent 730f689 commit 6ef107e

File tree

1 file changed

+3
-14
lines changed

1 file changed

+3
-14
lines changed

core/src/main/java/org/testcontainers/dockerclient/RootlessDockerClientProviderStrategy.java

+3-14
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,8 @@ private Path resolveSocketPath() {
3434
Path homePath = Paths.get(System.getProperty("user.home")).resolve(".docker").resolve("run");
3535
return tryFolder(homePath)
3636
.orElseGet(() -> {
37-
Path dockerDesktopPath = Paths
38-
.get(System.getProperty("user.home"))
39-
.resolve(".docker")
40-
.resolve("desktop");
41-
return tryFolder(dockerDesktopPath)
42-
.orElseGet(() -> {
43-
Path implicitPath = Paths.get("/run/user/" + LibC.INSTANCE.getuid());
44-
return tryFolder(implicitPath).orElse(null);
45-
});
37+
Path implicitPath = Paths.get("/run/user/" + LibC.INSTANCE.getuid());
38+
return tryFolder(implicitPath).orElse(null);
4639
});
4740
});
4841
}
@@ -86,11 +79,7 @@ public TransportConfig getTransportConfig() throws InvalidConfigurationException
8679

8780
@Override
8881
protected boolean isApplicable() {
89-
return (
90-
(SystemUtils.IS_OS_LINUX || SystemUtils.IS_OS_MAC) &&
91-
getSocketPath() != null &&
92-
Files.exists(getSocketPath())
93-
);
82+
return SystemUtils.IS_OS_LINUX && getSocketPath() != null && Files.exists(getSocketPath());
9483
}
9584

9685
@Override

0 commit comments

Comments
 (0)