HomePhabricator

standardize hiera-overridable class/config params

Authored by BBlack.

Description

standardize hiera-overridable class/config params

We had a few different ways of accomplishing the same thing here,
and increasingly many of these variables are likely to need to
cross into sibling classes during refactors as well. This
standardizes the pattern as:

  1. Class param in r::c::base
  2. Defaulted for prod in base.pp param list
  3. Labs override of r::c::b::foo in hieradata/labs.yaml
  4. per-cluster copy to $vcl_config as-needed
  5. always accessed from vcl_config.fetch() in templates
  6. no default-argument in the fetch() call

The affected variables standardized under this scheme are now:
zero_site
purge_host_only_upload_re
purge_host_not_upload_re
static_host
upload_domain
bits_domain
top_domain

This will likely change again at a later point, but it's a better
place to be for the moment in terms of factoring.

Bug: T96847
Bug: T109286
Change-Id: I6351b0897aaa7ac53ca4482037ff28c31cb9851c

Details

Committed
BBlackSep 1 2015, 4:30 AM
Parents
rOPUP4d4a71745417: vcl: merge cluster_options into vcl_config, refactor
Branches
Unknown
Tags
Unknown
ChangeId
I6351b0897aaa7ac53ca4482037ff28c31cb9851c