aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHåkon Hallingstad <hakon@oath.com>2018-09-26 20:27:59 +0200
committerHåkon Hallingstad <hakon@oath.com>2018-09-26 20:27:59 +0200
commit791c1fe58d80450377327ca0662940e995f087a0 (patch)
tree60193ba6ee2d58a1448c9bb1cdfa45a7f01e714b
parent213afb57f3f20b9d77ae3e8c465745e91c84f744 (diff)
Fix casing of serialized cloud
-rw-r--r--node-admin/src/main/java/com/yahoo/vespa/hosted/node/admin/docker/DockerNetworking.java2
-rw-r--r--node-admin/src/test/java/com/yahoo/vespa/hosted/node/admin/maintenance/acl/AclMaintainerTest.java4
2 files changed, 3 insertions, 3 deletions
diff --git a/node-admin/src/main/java/com/yahoo/vespa/hosted/node/admin/docker/DockerNetworking.java b/node-admin/src/main/java/com/yahoo/vespa/hosted/node/admin/docker/DockerNetworking.java
index 7678ad8169a..aee6397da5d 100644
--- a/node-admin/src/main/java/com/yahoo/vespa/hosted/node/admin/docker/DockerNetworking.java
+++ b/node-admin/src/main/java/com/yahoo/vespa/hosted/node/admin/docker/DockerNetworking.java
@@ -28,7 +28,7 @@ public enum DockerNetworking {
}
public static DockerNetworking from(String cloud, NodeType nodeType, boolean hostAdmin) {
- if (cloud.equals("AWS")) {
+ if (cloud.equals("aws")) {
return DockerNetworking.NPT;
} else if (nodeType == NodeType.confighost || nodeType == NodeType.proxyhost) {
return DockerNetworking.HOST_NETWORK;
diff --git a/node-admin/src/test/java/com/yahoo/vespa/hosted/node/admin/maintenance/acl/AclMaintainerTest.java b/node-admin/src/test/java/com/yahoo/vespa/hosted/node/admin/maintenance/acl/AclMaintainerTest.java
index 56373dda2f8..9d5555e1f92 100644
--- a/node-admin/src/test/java/com/yahoo/vespa/hosted/node/admin/maintenance/acl/AclMaintainerTest.java
+++ b/node-admin/src/test/java/com/yahoo/vespa/hosted/node/admin/maintenance/acl/AclMaintainerTest.java
@@ -49,13 +49,13 @@ public class AclMaintainerTest {
@Before
public void before() {
when(dockerOperations.getAllManagedContainers()).thenReturn(containerList);
- when(env.getCloud()).thenReturn("AWS");
+ when(env.getCloud()).thenReturn("aws");
when(env.getDockerNetworking()).thenReturn(DockerNetworking.NPT);
}
@Test
public void no_redirect_in_yahoo() {
- when(env.getCloud()).thenReturn("YAHOO");
+ when(env.getCloud()).thenReturn("yahoo");
when(env.getDockerNetworking()).thenReturn(DockerNetworking.MACVLAN);
Container container = addContainer("container1", "container1.host.com", Container.State.RUNNING);