Kf CLI Reference

CLI Reference

kf about

Print information about Kf’s terms of service.

kf app

Print information about the given App.

kf apps

List Apps in the targeted Space.

kf bind-route-service

Bind a route service instance to an HTTP route.

kf bind-service

Grant an App access to a service instance.

kf bindings

List bindings in the targeted Space.

kf build

Print information about the given Build.

kf build-logs

Get the logs of the given Build.

kf buildpacks

List buildpacks in the targeted Space.

kf builds

List Builds in the targeted Space.

kf configure-cluster

Set configuration for a cluster.

kf configure-cluster get-feature-flags

Get the values for feature flags set on the cluster.

kf configure-cluster set-feature-flag

Set a feature flag on the cluster.

kf configure-cluster unset-feature-flag

Unset a feature flag on the cluster. Resets feature flag value to default.

kf configure-space

Set configuration for a Space.

kf configure-space append-domain

Append a domain for a Space.

kf configure-space get-build-service-account

Get the service account that is used when building containers in the Space.

kf configure-space get-buildpack-env

Get the environment variables for Builds in a Space.

kf configure-space get-container-registry

Get the container registry used for Builds.

kf configure-space get-domains

Get domains associated with the Space.

kf configure-space get-execution-env

Get the Space wide App environment variables.

kf configure-space get-nodeselector

Get the node selector associated with the Space.

kf configure-space remove-domain

Remove a domain from a Space.

kf configure-space set-app-egress-policy

Set the egress policy for Apps in the Space.

kf configure-space set-app-ingress-policy

Set the ingress policy for Apps in the Space.

kf configure-space set-build-egress-policy

Set the egress policy for Builds in the Space.

kf configure-space set-build-ingress-policy

Set the ingress policy for Builds in the Space.

kf configure-space set-build-service-account

Set the service account to use when building containers.

kf configure-space set-buildpack-env

Set an environment variable for Builds in a Space.

kf configure-space set-container-registry

Set the container registry used for Builds.

kf configure-space set-default-domain

Set or create a default domain for a Space.

kf configure-space set-env

Set a Space wide environment variable for all Apps.

kf configure-space set-nodeselector

Set a Space wide node selector for all Apps.

kf configure-space unset-buildpack-env

Unset an environment variable for Builds in a Space.

kf configure-space unset-env

Unset a Space wide environment variable for all Apps.

kf configure-space unset-nodeselector

Unset a Space wide node selector for all Apps.

kf create-autoscaling-rule

Create autoscaling rule for App.

kf create-job

Create a Job on the App.

kf create-route

Create a traffic routing rule for a host+path pair.

kf create-service

Create a service instance from a marketplace template.

kf create-service-broker

Add a service broker to the marketplace.

kf create-space

Create a Space with the given name.

kf create-user-provided-service

Create a standalone service instance from existing credentials.

kf debug

Print debugging information useful for filing a bug report.

kf delete

Delete the App with the given name in the targeted Space.

kf delete-autoscaling-rules

Delete all autoscaling rules for App and disable autoscaling.

kf delete-job

Delete the Job with the given name in the targeted Space.

kf delete-job-schedule

Delete the schedule for a Job.

kf delete-network-policy

Delete the NetworkPolicy with the given name in the targeted Space.

kf delete-orphaned-routes

Delete Routes with no App bindings.

kf delete-route

Delete a Route in the targeted Space.

kf delete-service

Delete the ServiceInstance with the given name in the targeted Space.

kf delete-service-broker

Remove a service broker from the marketplace.

kf delete-space

Delete the Space with the given name.

kf disable-autoscaling

Disable autoscaling for App.

kf doctor

Run validation tests against one or more components.

kf domains

List domains that can be used in the targeted Space.

kf enable-autoscaling

Enable autoscaling for App.

kf env

Print information about an App’s environment variables.

kf fix-orphaned-bindings

Fix bindings without an app owner in a space.

kf job-history

List the execution history of a Job.

kf job-schedules

List job schedules in the targeted Space.

kf jobs

List Jobs in the targeted Space.

kf logs

Show logs for an App.

kf map-route

Grant an App access to receive traffic from the Route.

kf marketplace

List service classes available in the cluster.

kf network-policies

List network policies in the targeted Space.

kf network-policy

Print information about the given NetworkPolicy.

kf proxy

Start a local reverse proxy to an App.

kf proxy-route

Start a local reverse proxy to a Route.

kf push

Create a new App or apply updates to an existing one.

kf restage

Rebuild and redeploy an App without downtime.

kf restart

Restart each running instance of an App without downtime.

kf routes

List routes in the targeted Space.

kf run-job

Run the Job once.

kf run-task

Run a short-lived Task on the App.

kf scale

Change the horizontal or vertical scale of an App without downtime.

kf schedule-job

Schedule the Job for execution on a cron schedule.

kf service

Print information about the given ServiceInstance.

kf services

List services in the targeted Space.

kf set-env

Create or update an environment variable for an App.

kf set-space-role

Assgin a Role to a Subject (User|Group|ServiceAccount).

kf space

Print information about the given Space.

kf space-users

List users and their roles in a Space.

kf spaces

List Spaces in the cluster.

kf ssh

Open a shell on an App instance.

kf stacks

List stacks in the targeted Space.

kf start

Deploy a stopped App and route traffic to it once healthy.

kf stop

Remove instances of a running App and stop network traffic.

kf target

Set the default Space to run commands against.

kf tasks

List Tasks in the targeted Space.

kf terminate-task

Terminate a running Task.

kf unbind-route-service

Unbind a route service instance from an HTTP route.

kf unbind-service

Revoke an App’s access to a service instance.

kf unmap-route

Revoke an App’s access to receive traffic from the Route.

kf unset-env

Delete an environment variable on an App.

kf unset-space-role

Unassign a Role to a Subject.

kf update-autoscaling-limits

Update autoscaling limits for App.

kf update-user-provided-service

Update a standalone service instance with new credentials.

kf vcap-services

Print the VCAP_SERVICES environment variable for an App.

kf version

Print the CLI version.

kf wrap-v2-buildpack

Create a V3 buildpack that wraps a V2 buildpack.

kf xargs-apps

Run a command for every App.