F5Networks / charts

Helm charts for using F5 products and services in Kubernetes and OpenShift environments.
Apache License 2.0
28 stars 34 forks source link

[bug] using args.partition causes unknown flag #20

Open tkam8 opened 6 years ago

tkam8 commented 6 years ago

Description

When running below command to launch chart to deploy the controller, k8s controller pod goes from "Error" to "CrashLoopBackOff " and never gets created.

helm install --set args.bigip_url=1.2.3.4 --set args.partition=kubernetes --set bigip_login_secret=bigip-login --set serviceaccount=k8s-bigip-ctlr f5-stable/f5-bigip-ctlr

Repro:

  1. Install k8s
  2. setup flannel and setup BIG-IP dummy node
  3. setup bigip serviceaccount as necessary
  4. setup secret for bigip login
  5. install helm client and tiller
  6. run helm install command as shown above using parameter "args.partition"
  7. workaround is to change the parameter name to "bigip_partition"

Expected Behavior: Pod gets created

Actual Behavior: error

Request: please update the documentation if bigip_partition should be used as the parameter name when using the --set option.

Kubernetes Version

f5user@k8s-master:~$ kubectl version Client Version: version.Info{Major:"1", Minor:"12", GitVersion:"v1.12.1", GitCommit:"4ed3216f3ec431b140b1d899130a69fc671678f4", GitTreeState:"clean", BuildDate:"2018-10-05T16:46:06Z", GoVersion:"go1.10.4", Compiler:"gc", Platform:"linux/amd64"} Server Version: version.Info{Major:"1", Minor:"12", GitVersion:"v1.12.1", GitCommit:"4ed3216f3ec431b140b1d899130a69fc671678f4", GitTreeState:"clean", BuildDate:"2018-10-05T16:36:14Z", GoVersion:"go1.10.4", Compiler:"gc", Platform:"linux/amd64"}

Controller Version

f5user@k8s-master:~$ kubectl logs auxiliary-meerkat-f5-bigip-ctlr-5877c74b9b-j99ph -n kube-system 2018/10/24 15:19:05 [INFO] Starting: Version: v1.7.0, BuildInfo: n1260-443736128

BIG-IP Version

admin@(localhost)(cfg-sync Standalone)(Active)(/Common)(tmos)# show sys version

Sys::Version Main Package Product BIG-IP Version 13.1.1 Build 0.0.4 Edition Final Date Fri Jul 20 17:55:49 PDT 2018

Helm / Tiller Version

f5user@k8s-master:~$ helm version Client: &version.Version{SemVer:"v2.11.0", GitCommit:"2e55dbe1fdb5fdb96b75ff144a339489417b146b", GitTreeState:"clean"} Server: &version.Version{SemVer:"v2.11.0", GitCommit:"2e55dbe1fdb5fdb96b75ff144a339489417b146b", GitTreeState:"clean"}

Diagnostic Information

Note the "unknown flag" error in the logs:

f5user@k8s-master:~$ kubectl logs exegetical-markhor-f5-bigip-ctlr-84bc995db6-x5x4z -n kube-system
unknown flag: --partition
Usage of /app/bin/k8s-bigip-ctlr
  Global:
      --http-listen-address string   Optional, address to serve http based informations (/metrics and /health). (default "0.0.0.0:8080")
      --log-level string             Optional, logging level (default "INFO")
      --node-poll-interval int       Optional, interval (in seconds) at which to poll for cluster nodes. (default 30)
      --python-basedir string        DEPRECATED: Optional, directory location of python utilities
      --verify-interval int          Optional, interval (in seconds) at which to verify the BIG-IP configuration. (default 30)
      --version                      Optional, print version and exit.

  BigIP:
      --bigip-partition stringArray    Required, partition(s) for the Big-IP kubernetes objects.
      --bigip-password string          Required, password for the Big-IP user account.
      --bigip-url string               Required, URL for the Big-IP
      --bigip-username string          Required, user name for the Big-IP user account.
      --credentials-directory string   Optional, directory that contains the BIG-IP username, password, and/or url files. To be used instead of username, password, and/or url arguments.

  Kubernetes:

----snip----

tkam8 commented 6 years ago

Update:

upon further inspection, it looks like "helm inspect values" shows the right parameter name so should be sufficient documentation. I don't know where "args.partition" is valid, though. Any ideas?

f5user@k8s-master:~$ helm inspect values f5-stable/f5-bigip-ctlr
# For additional information on installing the k8-bigip-ctlr please see:
# Kubernetes: http://clouddocs.f5.com/containers/latest/kubernetes/kctlr-app-install.html
# OpenShift: http://clouddocs.f5.com/containers/latest/openshift/kctlr-openshift-app-install.html#install-kctlr-openshift
#
# access / permissions / RBAC
# To create a secret using kubectl see 
# http://clouddocs.f5.com/containers/latest/kubernetes/kctlr-secrets.html#secret-bigip-login
bigip_login_secret: f5-bigip-ctlr-login
serviceaccount: f5-bigip-ctlr-serviceaccount
# This namespace is where the Controller lives;
namespace: kube-system
args:
  # See http://clouddocs.f5.com/products/connectors/k8s-bigip-ctlr/latest/#controller-configuration-parameters
  # NOTE: helm has difficulty with values using `-`; `_` are used for naming
  # and are replaced with `-` during rendering.
  # REQUIRED Params
  bigip_url: ~
  bigip_partition: f5-bigip-ctlr
trinaths commented 3 years ago

@tkam8 - Can you verify with recent release of charts. that should fix the issue