Module: caf_deploy/plug_deploy_kubernetes

Deploys applications on Kubernetes on behalf of CAs.

The name of this component in framework.json should be 'deploy'

Properties:

  {refreshInterval: number,
   useK8SConfig: string, redis: caf.redis, app: caf.app}

where:

  • refreshInterval: time between Marathon status polling in msec.
  • useK8SConfig: whether to use the k8s config file from the kubelet client.
  • redis: configuration properties for the redis service.
  • app: configuration properties for deploying the app.

The type caf.redis is:

   {templateFile: string, k8SNamespace: string,
     image: string, cpus: number, memory: number, memoryLimit: number}

where:

  • templateFile: name of the Redis template.
  • k8SNamespace: a namespace for the instance.
  • image: Docker image for the redis service.
  • cpus, memory, memoryLimit: Fraction of cpu for the instance, memory in megabytes requested and its hard limit.

The type caf.app is:

   {templateFile: string, k8SNamespace: string, args: Array.<caf.json>,
    instances: number, memoryLimit: number, appSuffix: string,
    isDeployer: boolean, isAccounts: boolean,
    services: Array.<string>, cpus: number, memory: number}

where:

  • templateFile: name of the app template.
  • k8SNamespace: a namespace for the instance.
  • appSuffix: a common url suffix for apps, e.g., cafjs.com.
  • args: default app arguments.
  • instances: number of instances.
  • isDeployer: whether this is a privileged app that deploys others.
  • isAccounts: whether this is a privileged app that authenticates others.
  • services: dependent services like redis.
  • cpus, memory, memoryLimit: Fraction of cpu for the instance, memory in megabytes requested and its hard limit.
Source:

Extends