Skip to main content
Version: 1.1

wf create cluster

wf create cluster

Create a kubernetes cluster in the workspace

Synopsis

Lets you provision a kubernetes cluster in the workspace. The cluster itself is provisioned from a predefined plan (a template). You can view plans available to you by running:

$ wf get plans

Once the cluster is built, members of your workspace can get access by running:

$ wf login

wf create cluster [flags]

Examples


# Retrieve a list of all the plans available to you:
$ wf get plans

# See the detail of a specific plan:
$ wf get plans <name> -o yaml

# See the possible cloud accounts available to your workspace:
$ wf get cloudaccounts -w my_workspace

# Create a single nonprod cluster named dev:
$ wf -w my_workspace create cluster dev --plan gke-development --stage nonprod --cloud-account cloud_account_name

# Create two clusters named app1 and app2:
$ wf -w my_workspace create cluster dev --plan gke-development -s nonprod -a cloud_account_name --cluster=app1,app2

# Check the status of the cluster named dev:
$ wf -w my_workspace get cluster dev -o yaml

# Override plan parameters using --param:
$ wf -w my_workspace create cluster dev --param authProxyAllowedIPs.0=1.1.1.1/8
$ wf -w my_workspace create cluster dev --param authProxyAllowedIPs='["1.1.1.1/32","2,2,2,2"]'
$ wf -w my_workspace create cluster dev --param authProxyAllowedIPs.-1=127.0.0.0/8

# Alternatively you can use json directly:
$ wf -w my_workspace create cluster dev --param nodeGroups.1'='{json}|[json]'

# If you only have the one allocated cloud account for a cloud provider in your
# workspace you do not need to specify --cloud-account / -a. It will be automatically
# selected for you:
$ wf -w my_workspace create cluster dev --plan gke-development

# Once the cluster is created, update your kubeconfig to use it. This will
# modify ${HOME}/.kube/config with the connection details, allowing you to
# use 'kubectl' to interact with it:
$ wf kubeconfig -w my_workspace

# By default all access to clusters is short-lived, you must assume a set
# of permissions before working with clusters.
$ wf assume --help

Options

  -a, --cloud-account string     Name of the allocated cloud account / org to use for this cluster
-d, --description string A short description for the cluster
--dry-run Shows the resource but does not apply or create (defaults: false)
-h, --help help for cluster
-p, --plan string Plan that this cluster will be templated from
--service-account string Secret name holding the service account details
-T, --show-time Shows the time it took to successfully provision a new cluster
-s, --stage string The stage for this cluster

Options inherited from parent commands

      --debug              Indicates we should use debug / trace logging (default: false)
--force Used to force an operation to happen (default: false)
--no-wait Indicates we should not wait for resources to provision
-o, --output string Output format of the resource (json,yaml,table,template) (default "table")
--profile string Use a profile other than your default for this command
--show-headers Indicates we should display headers on table out (default true)
--verbose Enables verbose logging for debugging purposes (default: false)
-w, --workspace string The workspace you are operating within

SEE ALSO