| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent a5be86d commit fba4fd1
4 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -230,6 +230,12 @@ public class Info implements Serializable { | |||
| 230 | 230 | @JsonProperty("Swarm") | |
| 231 | 231 | private SwarmInfo swarm; | |
| 232 | 232 | ||
| 233 | + /** | ||
| 234 | + * @since {@link com.github.dockerjava.core.RemoteApiVersion#VERSION_1_25} | ||
| 235 | + */ | ||
| 236 | + @JsonProperty("Isolation") | ||
| 237 | + private String isolation; | ||
| 238 | + | ||
| 233 | 239 | /** | |
| 234 | 240 | * @see #architecture | |
| 235 | 241 | */ | |
@@ -1046,6 +1052,22 @@ public Info withSwarm(SwarmInfo swarm) { | |||
| 1046 | 1052 | return this; | |
| 1047 | 1053 | } | |
| 1048 | 1054 | ||
| 1055 | + /** | ||
| 1056 | + * @see #isolation | ||
| 1057 | + */ | ||
| 1058 | + @CheckForNull | ||
| 1059 | + public String getIsolation() { | ||
| 1060 | + return isolation; | ||
| 1061 | + } | ||
| 1062 | + | ||
| 1063 | + /** | ||
| 1064 | + * @see #isolation | ||
| 1065 | + */ | ||
| 1066 | + public Info withIsolation(String isolation) { | ||
| 1067 | + this.isolation = isolation; | ||
| 1068 | + return this; | ||
| 1069 | + } | ||
| 1070 | + | ||
| 1049 | 1071 | @Override | |
| 1050 | 1072 | public String toString() { | |
| 1051 | 1073 | return ToStringBuilder.reflectionToString(this); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -87,6 +87,8 @@ public class RemoteApiVersion implements Serializable { | |||
| 87 | 87 | public static final RemoteApiVersion VERSION_1_34 = RemoteApiVersion.create(1, 34); | |
| 88 | 88 | public static final RemoteApiVersion VERSION_1_35 = RemoteApiVersion.create(1, 35); | |
| 89 | 89 | public static final RemoteApiVersion VERSION_1_36 = RemoteApiVersion.create(1, 36); | |
| 90 | + public static final RemoteApiVersion VERSION_1_37 = RemoteApiVersion.create(1, 37); | ||
| 91 | + public static final RemoteApiVersion VERSION_1_38 = RemoteApiVersion.create(1, 38); | ||
| 90 | 92 | ||
| 91 | 93 | ||
| 92 | 94 | /** | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3,10 +3,12 @@ | |||
| 3 | 3 | import com.fasterxml.jackson.databind.JavaType; | |
| 4 | 4 | import com.fasterxml.jackson.databind.ObjectMapper; | |
| 5 | 5 | import com.github.dockerjava.api.model.InfoRegistryConfig.IndexConfig; | |
| 6 | + import com.github.dockerjava.core.RemoteApiVersion; | ||
| 6 | 7 | import org.hamcrest.CoreMatchers; | |
| 7 | 8 | import org.junit.Test; | |
| 8 | 9 | ||
| 9 | 10 | import java.io.IOException; | |
| 11 | + import java.util.Arrays; | ||
| 10 | 12 | import java.util.Collections; | |
| 11 | 13 | import java.util.LinkedHashMap; | |
| 12 | 14 | import java.util.List; | |
@@ -327,4 +329,39 @@ public void serder2Json() throws IOException { | |||
| 327 | 329 | ||
| 328 | 330 | assertThat(info, is(withInfo)); | |
| 329 | 331 | } | |
| 332 | + | ||
| 333 | + @Test | ||
| 334 | + public void info_1_38() throws IOException { | ||
| 335 | + final ObjectMapper mapper = new ObjectMapper(); | ||
| 336 | + final JavaType type = mapper.getTypeFactory().constructType(Info.class); | ||
| 337 | + | ||
| 338 | + final Info info = testRoundTrip(RemoteApiVersion.VERSION_1_38, | ||
| 339 | + "info/lcow.json", | ||
| 340 | + type | ||
| 341 | + ); | ||
| 342 | + | ||
| 343 | + assertThat(info, notNullValue()); | ||
| 344 | + assertThat(info.getArchitecture(), is("x86_64")); | ||
| 345 | + assertThat(info.getDockerRootDir(), is("C:\\ProgramData\\Docker")); | ||
| 346 | + assertThat(info.getDriver(), is("windowsfilter (windows) lcow (linux)")); | ||
| 347 | + | ||
| 348 | + assertThat(info.getDriverStatuses(), equalTo(Arrays.asList( | ||
| 349 | + Arrays.asList("Windows", ""), | ||
| 350 | + Arrays.asList("LCOW", "") | ||
| 351 | + ))); | ||
| 352 | + | ||
| 353 | + assertThat(info.getIsolation(), is("hyperv")); | ||
| 354 | + assertThat(info.getKernelVersion(), is("10.0 17134 (17134.1.amd64fre.rs4_release.180410-1804)")); | ||
| 355 | + assertThat(info.getOsType(), is("windows")); | ||
| 356 | + assertThat(info.getOperatingSystem(), is("Windows 10 Pro Version 1803 (OS Build 17134.228)")); | ||
| 357 | + | ||
| 358 | + final Map<String, List<String>> plugins = new LinkedHashMap<>(); | ||
| 359 | + plugins.put("Authorization", null); | ||
| 360 | + plugins.put("Log", asList("awslogs", "etwlogs", "fluentd", "gelf", "json-file", "logentries", "splunk", "syslog")); | ||
| 361 | + plugins.put("Network", asList("ics", "l2bridge", "l2tunnel", "nat", "null", "overlay", "transparent")); | ||
| 362 | + plugins.put("Volume", singletonList("local")); | ||
| 363 | + assertThat(info.getPlugins(), equalTo(plugins)); | ||
| 364 | + | ||
| 365 | + assertThat(info.getServerVersion(), is("18.06.1-ce")); | ||
| 366 | + } | ||
| 330 | 367 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,93 @@ | |||
| 1 | + { | ||
| 2 | + "Architecture": "x86_64", | ||
| 3 | + "BridgeNfIp6tables": true, | ||
| 4 | + "BridgeNfIptables": true, | ||
| 5 | + "CPUSet": false, | ||
| 6 | + "CPUShares": false, | ||
| 7 | + "CgroupDriver": "", | ||
| 8 | + "ClusterAdvertise": "", | ||
| 9 | + "ClusterStore": "", | ||
| 10 | + "ContainerdCommit": { | ||
| 11 | + "Expected": "", | ||
| 12 | + "ID": "" | ||
| 13 | + }, | ||
| 14 | + "Containers": 3, | ||
| 15 | + "ContainersPaused": 0, | ||
| 16 | + "ContainersRunning": 0, | ||
| 17 | + "ContainersStopped": 3, | ||
| 18 | + "CpuCfsPeriod": false, | ||
| 19 | + "CpuCfsQuota": false, | ||
| 20 | + "Debug": true, | ||
| 21 | + "DefaultRuntime": "", | ||
| 22 | + "DockerRootDir": "C:\\ProgramData\\Docker", | ||
| 23 | + "Driver": "windowsfilter (windows) lcow (linux)", | ||
| 24 | + "DriverStatus": [["Windows", ""], ["LCOW", ""]], | ||
| 25 | + "ExperimentalBuild": true, | ||
| 26 | + "GenericResources": null, | ||
| 27 | + "HttpProxy": "", | ||
| 28 | + "HttpsProxy": "", | ||
| 29 | + "ID": "ZOGT:VB24:YEPZ:Y7HU:JHPB:WNUE:UYQG:7YRY:VLZV:FLWV:R65B:ICZG", | ||
| 30 | + "IPv4Forwarding": true, | ||
| 31 | + "Images": 2, | ||
| 32 | + "IndexServerAddress": "https://index.docker.io/v1/", | ||
| 33 | + "InitBinary": "", | ||
| 34 | + "InitCommit": { | ||
| 35 | + "Expected": "", | ||
| 36 | + "ID": "" | ||
| 37 | + }, | ||
| 38 | + "Isolation": "hyperv", | ||
| 39 | + "KernelMemory": false, | ||
| 40 | + "KernelVersion": "10.0 17134 (17134.1.amd64fre.rs4_release.180410-1804)", | ||
| 41 | + "Labels": [], | ||
| 42 | + "LiveRestoreEnabled": false, | ||
| 43 | + "LoggingDriver": "json-file", | ||
| 44 | + "MemTotal": 68684476416, | ||
| 45 | + "MemoryLimit": false, | ||
| 46 | + "NCPU": 8, | ||
| 47 | + "NEventsListener": 1, | ||
| 48 | + "NFd": -1, | ||
| 49 | + "NGoroutines": 28, | ||
| 50 | + "Name": "somename", | ||
| 51 | + "NoProxy": "", | ||
| 52 | + "OSType": "windows", | ||
| 53 | + "OomKillDisable": false, | ||
| 54 | + "OperatingSystem": "Windows 10 Pro Version 1803 (OS Build 17134.228)", | ||
| 55 | + "Plugins": { | ||
| 56 | + "Authorization": null, | ||
| 57 | + "Log": ["awslogs", "etwlogs", "fluentd", "gelf", "json-file", "logentries", "splunk", "syslog"], | ||
| 58 | + "Network": ["ics", "l2bridge", "l2tunnel", "nat", "null", "overlay", "transparent"], | ||
| 59 | + "Volume": ["local"] | ||
| 60 | + }, | ||
| 61 | + "RegistryConfig": { | ||
| 62 | + "AllowNondistributableArtifactsCIDRs": [], | ||
| 63 | + "AllowNondistributableArtifactsHostnames": [], | ||
| 64 | + "IndexConfigs": { | ||
| 65 | + "docker.io": { | ||
| 66 | + "Mirrors": [], | ||
| 67 | + "Name": "docker.io", | ||
| 68 | + "Official": true, | ||
| 69 | + "Secure": true | ||
| 70 | + } | ||
| 71 | + }, | ||
| 72 | + "InsecureRegistryCIDRs": ["127.0.0.0/8"], | ||
| 73 | + "Mirrors": [] | ||
| 74 | + }, | ||
| 75 | + "RuncCommit": { | ||
| 76 | + "Expected": "", | ||
| 77 | + "ID": "" | ||
| 78 | + }, | ||
| 79 | + "Runtimes": null, | ||
| 80 | + "SecurityOptions": [], | ||
| 81 | + "ServerVersion": "18.06.1-ce", | ||
| 82 | + "SwapLimit": false, | ||
| 83 | + "Swarm": { | ||
| 84 | + "ControlAvailable": false, | ||
| 85 | + "Error": "", | ||
| 86 | + "LocalNodeState": "inactive", | ||
| 87 | + "NodeAddr": "", | ||
| 88 | + "NodeID": "", | ||
| 89 | + "RemoteManagers": null | ||
| 90 | + }, | ||
| 91 | + "SystemStatus": null, | ||
| 92 | + "SystemTime": "2018-09-14T09:40:05.1369294+02:00" | ||
| 93 | + } | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments