Skip to content
  • Angus Lees's avatar
    Accept a wider range of jsonnet result structures · e1285841
    Angus Lees authored
    There is some variation in jsonnet "result" conventions.  This change
    assumes the top level is a JSON object, and then walks down looking
    for objects with `apiVersion` & `kind` fields.
    
    While walking down, the current code will expand JSON arrays, and
    object values.
    
    In particular, this should correctly accept:
    - single-value JSON files
    - arrays (jsonnet --yaml-stream)
    - "filename->object" objects (jsonnet --multi)
    
    (Note that any v1.Lists encountered are still expanded in a
    second-pass, as before)
    e1285841