Skip to main content
Create anything the cluster serves from YAML: a quick Deployment to try something, a ConfigMap, or a whole set of objects pasted from a file. Nothing is created until the cluster has checked every one of them.
The Create from YAML dialog with template buttons, a YAML editor holding a Deployment, and the kubectl create command.The Create from YAML dialog with template buttons, a YAML editor holding a Deployment, and the kubectl create command.

Creating objects from YAML, starting from a template.

Open it

  • Press ⌘N (CtrlN on Windows and Linux), or choose File → New from YAML…
  • Choose the + button (Create from YAML) in the header.
  • In the command palette (⌘K), choose Create from YAML.
In your cluster: browsers keep ⌘N for a new window, so use the + button or the command palette.

Create objects

1

Start from a template, or paste your own

The editor starts with a Deployment. Choose another template to start from it instead, or replace the text with your own YAML.
2

Add more objects if you like

Separate objects with a line of ---, as in any multi-document YAML file.
3

Create them

Choose Create, or press ⌘S in the editor. KubeStacks checks everything, then creates each object, and shows the result for each one.
When everything is created, a notification confirms it, with an Open button that takes you to the first new object.

Templates

Each template is a small, working starting point. Choosing one replaces what’s in the editor. The Deployment and Service templates go together: create both, and the service reaches the deployment’s pods.

Namespaces

New objects go to the namespace you picked in the namespace menu, or to default when you’re looking at all namespaces. An object that names its own namespace in metadata.namespace goes there instead. The dialog’s header says where new objects go.

How it’s checked

KubeStacks checks your YAML in this order, and stops at the first problem:
1

The YAML parses

Each document must be valid YAML, and say what kind it is. There must be something to create.
2

The cluster serves the kind

Each object’s kind and apiVersion must be one the cluster serves. If a custom resource’s CustomResourceDefinition is in the same YAML, create the CRD first, then the resources.
3

The cluster accepts every object

Every object is sent as a dry run (dryRun=All). If the cluster refuses any of them, nothing is created, and you see why for each one.
4

Each object is created

Then the objects are created one by one, in order, with the outcome of each shown.
The equivalent command is kubectl create -f objects.yaml, with the namespace and context.
Because everything is checked first, a typo in the fifth object doesn’t leave you with the first four created and the rest missing.

Read-only clusters

In a read-only cluster, the dialog opens, but says that changes are turned off, and Create stays disabled.

Edit YAML

Change an existing object, with a dry run and a diff first.

Install a Helm chart

For whole applications, find a chart on Artifact Hub instead.