Options
All
  • Public
  • Public/Protected
  • All
Menu

Module @kosko/template-deployed-service

@kosko/template-deployed-service

Create a new component including a deployment and a service.

Usage

npx @kosko/template-deployed-service --name nginx --image nginx

Options

--name

Name of deployment and service. (Required)

--image

Container image. (Required)

--type

Service type. Default to ClusterIP.

--servicePort

Service port. Default to 80.

--containerPort

Container port. Default to 80.

--replicas

Number of replicas. Default to 1.

Index

Object literals

Object literals

Const template

template: object

description

description: string = "Create a new component including a deployment and a service"

generate

  • generate(__namedParameters: { containerPort: number; image: string; name: string; replicas: number; servicePort: number; type: string }): Promise<{ files: { content: string; path: string }[] }>
  • Parameters

    • __namedParameters: { containerPort: number; image: string; name: string; replicas: number; servicePort: number; type: string }
      • containerPort: number
      • image: string
      • name: string
      • replicas: number
      • servicePort: number
      • type: string

    Returns Promise<{ files: { content: string; path: string }[] }>

options

options: object

containerPort

containerPort: object

default

default: number = 80

description

description: string = "Container port"

type

type: "number" = "number"

image

image: object

description

description: string = "Container image"

required

required: true = true

type

type: "string" = "string"

name

name: object

description

description: string = "Name of deployment and service"

required

required: true = true

type

type: "string" = "string"

replicas

replicas: object

default

default: number = 1

description

description: string = "Number of replicas"

type

type: "number" = "number"

servicePort

servicePort: object

default

default: number = 80

description

description: string = "Service port"

type

type: "number" = "number"

type

type: object

default

default: string = "ClusterIP"

description

description: string = "Service type"

type

type: "string" = "string"

Generated using TypeDoc