summaryrefslogtreecommitdiffstats
path: root/robot/assets/cmpv2/k8s-mongo.yaml
blob: 010eb65c42fe957141530c12dfcba46e78bb9e98 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
tosca_definitions_version: cloudify_dsl_1_3
imports:
  - 'http://www.getcloudify.org/spec/cloudify/4.5.5/types.yaml'
  - 'plugin:k8splugin?version=>=3.4.2,<4.0.0'
inputs:
  tag_version:
    type: string
    description: Docker image to be used
    default: 'mongo'
  replicas:
    type: integer
    description: Number of instances
    default: 1
  service_component_type:
    type: string
    default: "mongo"
  service_component_name_override:
    type: string
    default: "mongo"
node_templates:
  mongo:
    type: dcae.nodes.ContainerizedServiceComponent
    interfaces:
      cloudify.interfaces.lifecycle:
        start:
          inputs:
            envs:
              MONGO_INITDB_ROOT_USERNAME: root
              MONGO_INITDB_ROOT_PASSWORD: zXcVbN123!
              MONGO_INITDB_DATABASE: pnf_simulator
            ports:
              - '27017:0'
    properties:
      service_component_type: { get_input: service_component_type }
      service_component_name_override: { get_input: service_component_name_override }
      image: { get_input: tag_version }
      replicas: { get_input: replicas }