JAEN

Kubernetes

kubectl expose

SafeExpose as a Service

kubectl expose deploy <name> --port=80

Generates a Service for an existing workload — quick exposure for testing.

Examples

  • kubectl expose deploy web --port=80 --type=NodePortExpose via NodePort

Syntax

kubectl expose <res> <name> --port=N [--type=NodePort]

Before you run it

Adds a Service only.

Related commands

The same reference, with no signal at all

Every command and flow from this site, held on your device and searchable with no connection. Free to install, no ads.

Get it free on the App Store