From f39418777b4380ddca2d217570e32b056754b5f8 Mon Sep 17 00:00:00 2001 From: Suraj Deshmukh Date: Mon, 11 Jan 2021 14:24:32 +0530 Subject: [PATCH 1/2] conformance test docs: Fix AWS instructions - This commit fixes the AWS instructions. - Modify the formatting to be able to add Packet related instructions. Signed-off-by: Suraj Deshmukh --- docs/run-conformance-tests.md | 28 +++++++++++++++++++++------- 1 file changed, 21 insertions(+), 7 deletions(-) diff --git a/docs/run-conformance-tests.md b/docs/run-conformance-tests.md index f70db4407..44ecd5fae 100644 --- a/docs/run-conformance-tests.md +++ b/docs/run-conformance-tests.md @@ -3,16 +3,30 @@ title: Conformance tests weight: 50 --- -This document enumerates the steps required to run conformance tests for various platforms supported by Lokomotive. +This document enumerates the steps required to run conformance tests for various platforms supported +by Lokomotive. -**Note**: There is only one caveat to consider when running tests for AWS. For other platforms you can run conformance tests without making special arrangements. +## Step 1: Platform specific preparations -## AWS +### Step 1.1: AWS -For AWS you need to make sure that node ports are allowed in the security group. To do so make sure you set the `expose_nodeports` cluster property to `true` in the AWS config. Read more about this flag in the [AWS reference docs](configuration-reference/platforms/aws.md). +For AWS you need to make sure that node ports are allowed in the security group. To do so, make sure +you set the `expose_nodeports` cluster property to `true` in the AWS config. Read more about this +flag in the [AWS reference docs](configuration-reference/platforms/aws.md). -To install the cluster on AWS follow the [AWS quick start guide](quickstarts/aws.md). +To install the AWS cluster, follow the [AWS quick start guide](quickstarts/aws.md). -## Running conformance tests +## Step 2: Disable the mutating webhook server -Follow the canonical document [here](https://github.com/cncf/k8s-conformance/blob/master/instructions.md) which instructs on installing sonobuoy and running tests. +Run the following commands to disable the mutating webhook server that disallows the usage `default` +service account tokens: + +```bash +kubectl delete MutatingWebhookConfiguration admission-webhook-server +``` + +## Step 3: Running conformance tests + +Follow the canonical document +[here](https://github.com/cncf/k8s-conformance/blob/master/instructions.md) which instructs on +installing sonobuoy and running tests. From c16ff15de610078b94190e2039d38dfc865d7fff Mon Sep 17 00:00:00 2001 From: Suraj Deshmukh Date: Mon, 11 Jan 2021 21:28:19 +0530 Subject: [PATCH 2/2] docs: Add steps for Packet conformance test Signed-off-by: Suraj Deshmukh --- docs/run-conformance-tests.md | 44 +++++++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) diff --git a/docs/run-conformance-tests.md b/docs/run-conformance-tests.md index 44ecd5fae..57c208263 100644 --- a/docs/run-conformance-tests.md +++ b/docs/run-conformance-tests.md @@ -16,6 +16,50 @@ flag in the [AWS reference docs](configuration-reference/platforms/aws.md). To install the AWS cluster, follow the [AWS quick start guide](quickstarts/aws.md). +### Step 1.2: Packet + +#### Step 1.2.1: Cluster Requirements + +Create a cluster with at least two worker nodes. Follow the [Packet quick start +guide](quickstarts/packet.md) to install a cluster. + +#### Step 1.2.2: Expose kube-proxy + +Edit the kube-proxy Daemonset config to expose the metrics port on all interfaces. Run the following +command to edit the configuration: + +```bash +kubectl -n kube-system edit ds kube-proxy +``` + +Change the following flag from `- --metrics-bind-address=$(HOST_IP)` to +`- --metrics-bind-address=0.0.0.0`. + +#### Step 1.2.3: Expose the node ports on the worker nodes + +Apply the following Calico configuration to expose the ports in the default node port range `30000` +to `32767`: + +```yaml +echo " +apiVersion: crd.projectcalico.org/v1 +kind: GlobalNetworkPolicy +metadata: + name: allow-nodeport +spec: + applyOnForward: true + ingress: + - action: Allow + destination: + ports: + - 30000:32767 + protocol: TCP + order: 20 + preDNAT: true + selector: nodetype == 'worker' +" | kubectl apply -f - +``` + ## Step 2: Disable the mutating webhook server Run the following commands to disable the mutating webhook server that disallows the usage `default`