Skip to main content
The design command manages cloud native infrastructure designs, allowing you to create, apply, view, and share infrastructure configurations.

Synopsis

mesheryctl design [subcommand] [flags]

Subcommands

  • apply - Deploy a design to your infrastructure
  • delete - Remove a design from the system
  • view - Display design details
  • list - List all available designs
  • import - Import designs from files or URLs
  • export - Export designs to files
  • onboard - Onboard designs to the catalog
  • offboard - Remove designs from the catalog

Global Flags

--token
string
Path to token file. Defaults to current context token. Short form: -t

apply

Deploy a design file to your infrastructure.

Usage

mesheryctl design apply [design-name] [flags]

Flags

--file
string
required
Path to design file or URL. Short form: -f
--skip-save
boolean
default:"false"
Skip saving the design to the database before applying

Examples

# Apply a local design file
mesheryctl design apply -f ./mydesign.yaml

# Apply from URL
mesheryctl design apply -f https://raw.githubusercontent.com/meshery/meshery/master/samples/bookinfo.yaml
When applying by name, if multiple designs match, you’ll be prompted to select one.

Sample Output

Applying design bookinfo-app
design applied
Deployment successful: 4 resources created

delete

Remove a design from Meshery.

Usage

mesheryctl design delete [design-name] [flags]

Flags

--file
string
Path to design file to delete. Short form: -f

Examples

# Delete by name
mesheryctl design delete bookinfo-app

# Delete from file
mesheryctl design delete -f design.yaml

view

Display detailed information about a design.

Usage

mesheryctl design view [design-name | design-id] [flags]

Flags

--output
string
default:"yaml"
Output format: yaml, json. Short form: -o
--all
boolean
default:"false"
View all designs. Short form: -a

Examples

# View design details in YAML
mesheryctl design view bookinfo

# View in JSON format
mesheryctl design view bookinfo -o json

Sample Output

name: bookinfo-app
version: 1.0.0
services:
  productpage:
    type: Deployment
    namespace: default
    settings:
      replicas: 1
  details:
    type: Service
    namespace: default

list

List all available designs.

Usage

mesheryctl design list [flags]

Flags

--count
boolean
default:"false"
Display only the total count of designs
--page
integer
default:"1"
Page number for pagination
--page-size
integer
default:"25"
Number of designs per page

Examples

# List all designs
mesheryctl design list

# Show only count
mesheryctl design list --count

Sample Output

DESIGN NAME           TYPE         CREATED              
bookinfo-app          kubernetes   2024-03-01 10:30:00  
nginx-deployment      kubernetes   2024-03-02 14:22:00  
istio-demo            service-mesh 2024-03-03 09:15:00  

Total: 3 designs

import

Import designs from files or URLs.

Usage

mesheryctl design import [flags]

Flags

--file
string
required
Path to design file or URL. Short form: -f
--source-type
string
Type of design source: helm, docker-compose, kubernetes

Examples

# Import a design file
mesheryctl design import -f ./design.yaml

# Import with source type
mesheryctl design import -f chart.yaml --source-type helm
Supported design formats include Kubernetes manifests, Helm charts, Docker Compose files, and Meshery-specific design formats.

export

Export designs to files.

Usage

mesheryctl design export [design-name] [flags]

Flags

--output
string
default:"./design.yaml"
Output file path. Short form: -o
--format
string
default:"yaml"
Export format: yaml, json

Examples

# Export to file
mesheryctl design export bookinfo -o bookinfo.yaml

# Export as JSON
mesheryctl design export bookinfo -o bookinfo.json --format json

onboard

Onboard designs to the public catalog.

Usage

mesheryctl design onboard [design-name] [flags]

Flags

--file
string
Path to design file to onboard. Short form: -f

Examples

# Onboard a design to catalog
mesheryctl design onboard bookinfo

# Onboard from file
mesheryctl design onboard -f design.yaml

offboard

Remove designs from the catalog.

Usage

mesheryctl design offboard [design-name]

Examples

# Remove from catalog
mesheryctl design offboard bookinfo

Design File Format

Meshery design files use YAML or JSON format:
name: sample-design
version: 1.0.0
services:
  my-service:
    type: Deployment
    namespace: default
    settings:
      replicas: 3
      image: nginx:latest

Troubleshooting

Design Apply Fails

# Validate design syntax first
mesheryctl design view my-design

# Check logs for detailed errors
mesheryctl system logs

Import Errors

# Ensure source type is correct
mesheryctl design import -f myfile.yaml --source-type kubernetes

# Verify file format and syntax
cat myfile.yaml | yamllint

Design Not Found

# List all available designs
mesheryctl design list

# Search for design name
mesheryctl design list | grep my-design