From 2739fa6312dbb61172db162a32b634918d55cbd1 Mon Sep 17 00:00:00 2001 From: Adi Sosnovich <82078442+adisos@users.noreply.github.com> Date: Tue, 14 Jan 2025 12:17:21 +0200 Subject: [PATCH] update tests manifests (#477) Signed-off-by: adisos --- .../anp_banp_blog_demo_connlist_output.csv | 28 ++++++------- .../anp_banp_blog_demo_connlist_output.dot | 36 ++++++++-------- .../anp_banp_blog_demo_connlist_output.json | 42 +++++++++---------- .../anp_banp_blog_demo_connlist_output.md | 28 ++++++------- .../anp_banp_blog_demo_connlist_output.txt | 28 ++++++------- tests/anp_banp_blog_demo/policies.yaml | 4 +- tests/anp_banp_blog_demo/workloads.yaml | 16 +++---- 7 files changed, 91 insertions(+), 91 deletions(-) diff --git a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.csv b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.csv index e93ba5ad..2bac7d68 100644 --- a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.csv +++ b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.csv @@ -1,15 +1,15 @@ src,dst,conn -0.0.0.0-255.255.255.255,bar/my-bar[Pod],All Connections -0.0.0.0-255.255.255.255,baz/my-baz[Pod],All Connections -0.0.0.0-255.255.255.255,monitoring/my-monitoring[Pod],All Connections -bar/my-bar[Pod],0.0.0.0-255.255.255.255,All Connections -bar/my-bar[Pod],baz/my-baz[Pod],All Connections -bar/my-bar[Pod],monitoring/my-monitoring[Pod],All Connections -baz/my-baz[Pod],0.0.0.0-255.255.255.255,All Connections -baz/my-baz[Pod],monitoring/my-monitoring[Pod],All Connections -foo/my-foo[Pod],0.0.0.0-255.255.255.255,All Connections -foo/my-foo[Pod],baz/my-baz[Pod],All Connections -foo/my-foo[Pod],monitoring/my-monitoring[Pod],All Connections -monitoring/my-monitoring[Pod],0.0.0.0-255.255.255.255,All Connections -monitoring/my-monitoring[Pod],baz/my-baz[Pod],All Connections -monitoring/my-monitoring[Pod],foo/my-foo[Pod],All Connections +0.0.0.0-255.255.255.255,bar/mybar[Pod],All Connections +0.0.0.0-255.255.255.255,baz/mybaz[Pod],All Connections +0.0.0.0-255.255.255.255,monitoring/mymonitoring[Pod],All Connections +bar/mybar[Pod],0.0.0.0-255.255.255.255,All Connections +bar/mybar[Pod],baz/mybaz[Pod],All Connections +bar/mybar[Pod],monitoring/mymonitoring[Pod],All Connections +baz/mybaz[Pod],0.0.0.0-255.255.255.255,All Connections +baz/mybaz[Pod],monitoring/mymonitoring[Pod],All Connections +foo/myfoo[Pod],0.0.0.0-255.255.255.255,All Connections +foo/myfoo[Pod],baz/mybaz[Pod],All Connections +foo/myfoo[Pod],monitoring/mymonitoring[Pod],All Connections +monitoring/mymonitoring[Pod],0.0.0.0-255.255.255.255,All Connections +monitoring/mymonitoring[Pod],baz/mybaz[Pod],All Connections +monitoring/mymonitoring[Pod],foo/myfoo[Pod],All Connections diff --git a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.dot b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.dot index a9b8a1d4..7d94ce77 100644 --- a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.dot +++ b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.dot @@ -2,40 +2,40 @@ digraph { subgraph "cluster_bar" { color="black" fontcolor="black" - "bar/my-bar[Pod]" [label="my-bar[Pod]" color="blue" fontcolor="blue"] + "bar/mybar[Pod]" [label="mybar[Pod]" color="blue" fontcolor="blue"] label="bar" } subgraph "cluster_baz" { color="black" fontcolor="black" - "baz/my-baz[Pod]" [label="my-baz[Pod]" color="blue" fontcolor="blue"] + "baz/mybaz[Pod]" [label="mybaz[Pod]" color="blue" fontcolor="blue"] label="baz" } subgraph "cluster_foo" { color="black" fontcolor="black" - "foo/my-foo[Pod]" [label="my-foo[Pod]" color="blue" fontcolor="blue"] + "foo/myfoo[Pod]" [label="myfoo[Pod]" color="blue" fontcolor="blue"] label="foo" } subgraph "cluster_monitoring" { color="black" fontcolor="black" - "monitoring/my-monitoring[Pod]" [label="my-monitoring[Pod]" color="blue" fontcolor="blue"] + "monitoring/mymonitoring[Pod]" [label="mymonitoring[Pod]" color="blue" fontcolor="blue"] label="monitoring" } "0.0.0.0-255.255.255.255" [label="0.0.0.0-255.255.255.255" color="red2" fontcolor="red2"] - "0.0.0.0-255.255.255.255" -> "bar/my-bar[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "0.0.0.0-255.255.255.255" -> "baz/my-baz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "0.0.0.0-255.255.255.255" -> "monitoring/my-monitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "bar/my-bar[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] - "bar/my-bar[Pod]" -> "baz/my-baz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "bar/my-bar[Pod]" -> "monitoring/my-monitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "baz/my-baz[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] - "baz/my-baz[Pod]" -> "monitoring/my-monitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "foo/my-foo[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] - "foo/my-foo[Pod]" -> "baz/my-baz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] - "foo/my-foo[Pod]" -> "monitoring/my-monitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] - "monitoring/my-monitoring[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] - "monitoring/my-monitoring[Pod]" -> "baz/my-baz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] - "monitoring/my-monitoring[Pod]" -> "foo/my-foo[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "0.0.0.0-255.255.255.255" -> "bar/mybar[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "0.0.0.0-255.255.255.255" -> "baz/mybaz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "0.0.0.0-255.255.255.255" -> "monitoring/mymonitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "bar/mybar[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "bar/mybar[Pod]" -> "baz/mybaz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "bar/mybar[Pod]" -> "monitoring/mymonitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "baz/mybaz[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "baz/mybaz[Pod]" -> "monitoring/mymonitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "foo/myfoo[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "foo/myfoo[Pod]" -> "baz/mybaz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "foo/myfoo[Pod]" -> "monitoring/mymonitoring[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=0.5] + "monitoring/mymonitoring[Pod]" -> "0.0.0.0-255.255.255.255" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "monitoring/mymonitoring[Pod]" -> "baz/mybaz[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] + "monitoring/mymonitoring[Pod]" -> "foo/myfoo[Pod]" [label="All Connections" color="gold2" fontcolor="darkgreen" weight=1] } \ No newline at end of file diff --git a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.json b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.json index cdaf9c9c..5dbdd6a8 100644 --- a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.json +++ b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.json @@ -1,72 +1,72 @@ [ { "src": "0.0.0.0-255.255.255.255", - "dst": "bar/my-bar[Pod]", + "dst": "bar/mybar[Pod]", "conn": "All Connections" }, { "src": "0.0.0.0-255.255.255.255", - "dst": "baz/my-baz[Pod]", + "dst": "baz/mybaz[Pod]", "conn": "All Connections" }, { "src": "0.0.0.0-255.255.255.255", - "dst": "monitoring/my-monitoring[Pod]", + "dst": "monitoring/mymonitoring[Pod]", "conn": "All Connections" }, { - "src": "bar/my-bar[Pod]", + "src": "bar/mybar[Pod]", "dst": "0.0.0.0-255.255.255.255", "conn": "All Connections" }, { - "src": "bar/my-bar[Pod]", - "dst": "baz/my-baz[Pod]", + "src": "bar/mybar[Pod]", + "dst": "baz/mybaz[Pod]", "conn": "All Connections" }, { - "src": "bar/my-bar[Pod]", - "dst": "monitoring/my-monitoring[Pod]", + "src": "bar/mybar[Pod]", + "dst": "monitoring/mymonitoring[Pod]", "conn": "All Connections" }, { - "src": "baz/my-baz[Pod]", + "src": "baz/mybaz[Pod]", "dst": "0.0.0.0-255.255.255.255", "conn": "All Connections" }, { - "src": "baz/my-baz[Pod]", - "dst": "monitoring/my-monitoring[Pod]", + "src": "baz/mybaz[Pod]", + "dst": "monitoring/mymonitoring[Pod]", "conn": "All Connections" }, { - "src": "foo/my-foo[Pod]", + "src": "foo/myfoo[Pod]", "dst": "0.0.0.0-255.255.255.255", "conn": "All Connections" }, { - "src": "foo/my-foo[Pod]", - "dst": "baz/my-baz[Pod]", + "src": "foo/myfoo[Pod]", + "dst": "baz/mybaz[Pod]", "conn": "All Connections" }, { - "src": "foo/my-foo[Pod]", - "dst": "monitoring/my-monitoring[Pod]", + "src": "foo/myfoo[Pod]", + "dst": "monitoring/mymonitoring[Pod]", "conn": "All Connections" }, { - "src": "monitoring/my-monitoring[Pod]", + "src": "monitoring/mymonitoring[Pod]", "dst": "0.0.0.0-255.255.255.255", "conn": "All Connections" }, { - "src": "monitoring/my-monitoring[Pod]", - "dst": "baz/my-baz[Pod]", + "src": "monitoring/mymonitoring[Pod]", + "dst": "baz/mybaz[Pod]", "conn": "All Connections" }, { - "src": "monitoring/my-monitoring[Pod]", - "dst": "foo/my-foo[Pod]", + "src": "monitoring/mymonitoring[Pod]", + "dst": "foo/myfoo[Pod]", "conn": "All Connections" } ] \ No newline at end of file diff --git a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.md b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.md index 6fecb2a9..16c1b5f4 100644 --- a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.md +++ b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.md @@ -1,16 +1,16 @@ | src | dst | conn | |-----|-----|------| -| 0.0.0.0-255.255.255.255 | bar/my-bar[Pod] | All Connections | -| 0.0.0.0-255.255.255.255 | baz/my-baz[Pod] | All Connections | -| 0.0.0.0-255.255.255.255 | monitoring/my-monitoring[Pod] | All Connections | -| bar/my-bar[Pod] | 0.0.0.0-255.255.255.255 | All Connections | -| bar/my-bar[Pod] | baz/my-baz[Pod] | All Connections | -| bar/my-bar[Pod] | monitoring/my-monitoring[Pod] | All Connections | -| baz/my-baz[Pod] | 0.0.0.0-255.255.255.255 | All Connections | -| baz/my-baz[Pod] | monitoring/my-monitoring[Pod] | All Connections | -| foo/my-foo[Pod] | 0.0.0.0-255.255.255.255 | All Connections | -| foo/my-foo[Pod] | baz/my-baz[Pod] | All Connections | -| foo/my-foo[Pod] | monitoring/my-monitoring[Pod] | All Connections | -| monitoring/my-monitoring[Pod] | 0.0.0.0-255.255.255.255 | All Connections | -| monitoring/my-monitoring[Pod] | baz/my-baz[Pod] | All Connections | -| monitoring/my-monitoring[Pod] | foo/my-foo[Pod] | All Connections | +| 0.0.0.0-255.255.255.255 | bar/mybar[Pod] | All Connections | +| 0.0.0.0-255.255.255.255 | baz/mybaz[Pod] | All Connections | +| 0.0.0.0-255.255.255.255 | monitoring/mymonitoring[Pod] | All Connections | +| bar/mybar[Pod] | 0.0.0.0-255.255.255.255 | All Connections | +| bar/mybar[Pod] | baz/mybaz[Pod] | All Connections | +| bar/mybar[Pod] | monitoring/mymonitoring[Pod] | All Connections | +| baz/mybaz[Pod] | 0.0.0.0-255.255.255.255 | All Connections | +| baz/mybaz[Pod] | monitoring/mymonitoring[Pod] | All Connections | +| foo/myfoo[Pod] | 0.0.0.0-255.255.255.255 | All Connections | +| foo/myfoo[Pod] | baz/mybaz[Pod] | All Connections | +| foo/myfoo[Pod] | monitoring/mymonitoring[Pod] | All Connections | +| monitoring/mymonitoring[Pod] | 0.0.0.0-255.255.255.255 | All Connections | +| monitoring/mymonitoring[Pod] | baz/mybaz[Pod] | All Connections | +| monitoring/mymonitoring[Pod] | foo/myfoo[Pod] | All Connections | diff --git a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.txt b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.txt index b0253eb2..9b507f76 100644 --- a/test_outputs/connlist/anp_banp_blog_demo_connlist_output.txt +++ b/test_outputs/connlist/anp_banp_blog_demo_connlist_output.txt @@ -1,14 +1,14 @@ -0.0.0.0-255.255.255.255 => bar/my-bar[Pod] : All Connections -0.0.0.0-255.255.255.255 => baz/my-baz[Pod] : All Connections -0.0.0.0-255.255.255.255 => monitoring/my-monitoring[Pod] : All Connections -bar/my-bar[Pod] => 0.0.0.0-255.255.255.255 : All Connections -bar/my-bar[Pod] => baz/my-baz[Pod] : All Connections -bar/my-bar[Pod] => monitoring/my-monitoring[Pod] : All Connections -baz/my-baz[Pod] => 0.0.0.0-255.255.255.255 : All Connections -baz/my-baz[Pod] => monitoring/my-monitoring[Pod] : All Connections -foo/my-foo[Pod] => 0.0.0.0-255.255.255.255 : All Connections -foo/my-foo[Pod] => baz/my-baz[Pod] : All Connections -foo/my-foo[Pod] => monitoring/my-monitoring[Pod] : All Connections -monitoring/my-monitoring[Pod] => 0.0.0.0-255.255.255.255 : All Connections -monitoring/my-monitoring[Pod] => baz/my-baz[Pod] : All Connections -monitoring/my-monitoring[Pod] => foo/my-foo[Pod] : All Connections +0.0.0.0-255.255.255.255 => bar/mybar[Pod] : All Connections +0.0.0.0-255.255.255.255 => baz/mybaz[Pod] : All Connections +0.0.0.0-255.255.255.255 => monitoring/mymonitoring[Pod] : All Connections +bar/mybar[Pod] => 0.0.0.0-255.255.255.255 : All Connections +bar/mybar[Pod] => baz/mybaz[Pod] : All Connections +bar/mybar[Pod] => monitoring/mymonitoring[Pod] : All Connections +baz/mybaz[Pod] => 0.0.0.0-255.255.255.255 : All Connections +baz/mybaz[Pod] => monitoring/mymonitoring[Pod] : All Connections +foo/myfoo[Pod] => 0.0.0.0-255.255.255.255 : All Connections +foo/myfoo[Pod] => baz/mybaz[Pod] : All Connections +foo/myfoo[Pod] => monitoring/mymonitoring[Pod] : All Connections +monitoring/mymonitoring[Pod] => 0.0.0.0-255.255.255.255 : All Connections +monitoring/mymonitoring[Pod] => baz/mybaz[Pod] : All Connections +monitoring/mymonitoring[Pod] => foo/myfoo[Pod] : All Connections diff --git a/tests/anp_banp_blog_demo/policies.yaml b/tests/anp_banp_blog_demo/policies.yaml index 220bd250..0f9ee3e4 100644 --- a/tests/anp_banp_blog_demo/policies.yaml +++ b/tests/anp_banp_blog_demo/policies.yaml @@ -4,7 +4,7 @@ metadata: name: allow-monitoring namespace: foo spec: - podSelector: + podSelector: {} policyTypes: - Ingress ingress: @@ -69,4 +69,4 @@ spec: from: - namespaces: matchLabels: - kubernetes.io/metadata.name: monitoring + kubernetes.io/metadata.name: monitoring \ No newline at end of file diff --git a/tests/anp_banp_blog_demo/workloads.yaml b/tests/anp_banp_blog_demo/workloads.yaml index 00b070ff..51061e87 100644 --- a/tests/anp_banp_blog_demo/workloads.yaml +++ b/tests/anp_banp_blog_demo/workloads.yaml @@ -2,12 +2,12 @@ apiVersion: v1 kind: Pod metadata: namespace: foo - name: my-foo + name: myfoo labels: security: internal spec: containers: - - name: myfirstContainer + - name: myfirstcontainer image: fooimage --- @@ -16,12 +16,12 @@ apiVersion: v1 kind: Pod metadata: namespace: bar - name: my-bar + name: mybar labels: security: internal spec: containers: - - name: myfirstContainer + - name: myfirstcontainer image: barimage --- @@ -30,12 +30,12 @@ apiVersion: v1 kind: Pod metadata: namespace: baz - name: my-baz + name: mybaz labels: security: none spec: containers: - - name: myfirstContainer + - name: myfirstcontainer image: bazimage --- @@ -44,12 +44,12 @@ apiVersion: v1 kind: Pod metadata: namespace: monitoring - name: my-monitoring + name: mymonitoring labels: security: monitoring spec: containers: - - name: myfirstContainer + - name: myfirstcontainer image: monitoringimage ---