From ffa6e22cdde097522bcb3172f3e133b6f0756275 Mon Sep 17 00:00:00 2001 From: Antonin Bas Date: Fri, 8 Apr 2022 15:22:30 -0700 Subject: [PATCH] Address review comments Signed-off-by: Antonin Bas --- .github/workflows/go.yml | 9 ++++++ .github/workflows/helm_docs.yml | 31 ------------------- build/charts/antrea/README.md | 2 +- .../charts/antrea/conf/antrea-controller.conf | 2 +- .../antrea/templates/agent/daemonset.yaml | 3 -- build/charts/antrea/values.yaml | 2 +- hack/generate-standard-manifests.sh | 4 +++ 7 files changed, 16 insertions(+), 37 deletions(-) delete mode 100644 .github/workflows/helm_docs.yml diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 4da5667d4ff..712c0a73b08 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -224,6 +224,15 @@ jobs: run: | sudo npm install -g markdownlint-cli@0.31.1 make markdownlint + - name: Checking whether autogenerated Helm chart documentation is up-to-date + working-directory: build/charts/ + run: | + make helm-docs + DIFF=$(git diff .) + if [ -n "$DIFF" ]; then + echo "The Helm chart documentation is out-of-date; please run 'make helm-docs' in 'build/charts/' and commit the changes" + exit 1 + fi benchmark: needs: check-changes diff --git a/.github/workflows/helm_docs.yml b/.github/workflows/helm_docs.yml deleted file mode 100644 index 75ccb054c50..00000000000 --- a/.github/workflows/helm_docs.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: Helm docs -on: - pull_request: - branches: - - main - - release-* - - feature/* - push: - branches: - - main - - release-* - - feature/* - -jobs: - check-helm-docs: - name: Check whether autogenerated Helm chart documentation is up-to-date - runs-on: [ubuntu-latest] - steps: - - uses: actions/checkout@v3 - - name: Run helm-docs - working-directory: build/charts/ - run: | - make helm-docs - - name: Check for changes - working-directory: build/charts/ - run: | - DIFF=$(git diff .) - if [ -n "$DIFF" ]; then - echo "The Helm chart documentation is out-of-date; please run 'make helm-docs' in 'build/charts/' and commit the changes" - exit 1 - fi diff --git a/build/charts/antrea/README.md b/build/charts/antrea/README.md index a45d80097b6..9005e7c0b0d 100644 --- a/build/charts/antrea/README.md +++ b/build/charts/antrea/README.md @@ -60,7 +60,7 @@ Kubernetes: `>= 1.16.0-0` | controller.podAnnotations | object | `{}` | Annotations to be added to antrea-controller Pod. | | controller.podLabels | object | `{}` | Labels to be added to antrea-controller Pod. | | controller.priorityClassName | string | `"system-cluster-critical"` | Prority class to use for the antrea-controller Pod. | -| controller.selfSigned | bool | `true` | Indicates whether to use auto-generated self-signed TLS certificates. If false, a Secret named "antrea-controller-tls" must be provided with the following keys: ca.crt, tls.crt, tls.key. | +| controller.selfSignedCert | bool | `true` | Indicates whether to use auto-generated self-signed TLS certificates. If false, a Secret named "antrea-controller-tls" must be provided with the following keys: ca.crt, tls.crt, tls.key. | | controller.tolerations | list | `[{"key":"CriticalAddonsOnly","operator":"Exists"},{"effect":"NoSchedule","key":"node-role.kubernetes.io/master"}]` | Tolerations for the antrea-controller Pod. | | defaultMTU | int | `0` | Default MTU to use for the host gateway interface and the network interface of each Pod. By default, antrea-agent will discover the MTU of the Node's primary interface and adjust it to accommodate for tunnel encapsulation overhead if applicable. | | egress.exceptCIDRs | list | `[]` | CIDR ranges to which outbound Pod traffic will not be SNAT'd by Egresses. | diff --git a/build/charts/antrea/conf/antrea-controller.conf b/build/charts/antrea/conf/antrea-controller.conf index 182512e8a56..33ba3cab32c 100644 --- a/build/charts/antrea/conf/antrea-controller.conf +++ b/build/charts/antrea/conf/antrea-controller.conf @@ -37,7 +37,7 @@ enablePrometheusMetrics: {{ .Values.controller.enablePrometheusMetrics }} # ca.crt: # tls.crt: # tls.key: -selfSignedCert: {{ .Values.controller.selfSigned }} +selfSignedCert: {{ .Values.controller.selfSignedCert }} # Comma-separated list of Cipher Suites. If omitted, the default Go Cipher Suites will be used. # https://golang.org/pkg/crypto/tls/#pkg-constants diff --git a/build/charts/antrea/templates/agent/daemonset.yaml b/build/charts/antrea/templates/agent/daemonset.yaml index fcac4639473..5292dce279f 100644 --- a/build/charts/antrea/templates/agent/daemonset.yaml +++ b/build/charts/antrea/templates/agent/daemonset.yaml @@ -244,9 +244,6 @@ spec: args: - "--log_file_max_size={{ .Values.agent.antreaOVS.logFileMaxSize }}" - "--log_file_max_num={{ .Values.agent.antreaOVS.logFileMaxNum }}" - {{- if .Values.logVerbosity }} - - "--v={{ .Values.logVerbosity }}" - {{- end }} {{- if .Values.hwOffload }} - "--hw-offload" {{- end }} diff --git a/build/charts/antrea/values.yaml b/build/charts/antrea/values.yaml index 3f9b6a242ae..8a587f202b3 100644 --- a/build/charts/antrea/values.yaml +++ b/build/charts/antrea/values.yaml @@ -194,7 +194,7 @@ controller: # -- Indicates whether to use auto-generated self-signed TLS certificates. If # false, a Secret named "antrea-controller-tls" must be provided with the # following keys: ca.crt, tls.crt, tls.key. - selfSigned: true + selfSignedCert: true # -- Tolerations for the antrea-controller Pod. tolerations: # Mark it as a critical add-on. diff --git a/hack/generate-standard-manifests.sh b/hack/generate-standard-manifests.sh index 5319a0b43cb..a9626f154e8 100755 --- a/hack/generate-standard-manifests.sh +++ b/hack/generate-standard-manifests.sh @@ -100,6 +100,10 @@ fi THIS_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" +# Avoid potential Helm warnings about invalid permissions for Kubeconfig file. +# The Kubeconfig does not matter for "helm template". +unset KUBECONFIG + source $THIS_DIR/verify-helm.sh if [ -z "$HELM" ]; then