cloudfoundry-incubator / fissile

Turn a BOSH release into container images / files
Apache License 2.0
67 stars 36 forks source link

Role manifest shared volume validation bug #488

Closed HeavyWombat closed 5 years ago

HeavyWombat commented 5 years ago

We ran into an issue where the role manifest validation failed for our setup, where one instance group has multiple colocated container instance groups. Not all of the colocated instance groups have an emptyDir volume defined.

However, the validation we initially wrote for fissile did not take that scenario into account and simply checked that the number of volumes match. This does not work for the aforementioned setup. The number of colocated containers is two, but the number of volumes is one. Therefore, the validation fails.

instance_groups:
- name: main-instance-group
  jobs:
  - name: tor
    release: tor
    properties:
      bosh_containerization:
        colocated_containers:
        - to-be-colocated-1
        - to-be-colocated-2
        run:
          memory: 1
          volumes:
          - path: /shared/data
            type: emptyDir
            tag: shared-data

- name: to-be-colocated-1
  type: colocated-container
  jobs:
  - name: tor
    release: tor
    properties:
      bosh_containerization:
        run:
          memory: 1
          volumes:
          - path: /shared/data
            type: emptyDir
            tag: shared-data

- name: to-be-colocated-2
  type: colocated-container
  jobs:
  - name: ntpd
    release: ntp
    properties:
      bosh_containerization:
        # no volume defined here ...
        run:
          memory: 1
HeavyWombat commented 5 years ago

@tareqmamari FYI