Skip to content
This repository was archived by the owner on Nov 30, 2017. It is now read-only.
This repository was archived by the owner on Nov 30, 2017. It is now read-only.

sanity-test should fail fast when properties are missing #16

@bodymindarts

Description

@bodymindarts

When properties for the fog-check script in sanity-test aren't set sanity-test runs but fails:

+ fog-check
+ cat /var/vcap/jobs/sanity-test/config/fog-clusterdata.yml

+ cat /var/vcap/jobs/sanity-test/config/fog-databasestorage.yml

+ cd /var/vcap/packages/dingo-postgresql-fog-check
+ bundle exec bin/dingo-postgresql-fog-check /var/vcap/jobs/sanity-test/config/fog-clusterdata.yml /var/vcap/jobs/sanity-test/config/fog-databasestorage.yml

File /var/vcap/jobs/sanity-test/config/fog-clusterdata.yml could not be found or YAML parsed

The reason is because the fog-clusterdata.yml conditionally adds the properties:

<% if_p("backups.clusterdata.aws_access_key_id", "backups.clusterdata.aws_secret_access_key", "backups.clusterdata.bucket_name") do |aws_access_key_id, aws_secret_access_key, bucket_name| %>
...

Either the properties are mandatory and we don't use if_p making sanity-test fail when trying to provision (due to missing properties) or if the properties are really optional then sanity test shouldn't fail when those properties are not present.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions