--- tags: - puppet references: - https://www.puppet.com/docs/puppet/7/lang_classes#lang_class_declare --- Prefer include over resource-like; more flexible and idempotent. Resource-like to pass args without needing to use hieradata. > Mixing declaration types for the same class can lead to compilation errors. # Include-like <- preferred Relies on external data, e.g hieradata, and defaults. Idempotent: it is only added to the catalog once. ### `include` Accepts: single class, class reference (`Class[..]`), comma-seperated list of those or an array of them. ## `require` Same as above - but the class becomes a dependency of the container. #clarify dependency. ## `contain` Adheres to same rules as above. Relationships of the containing class extend to the contained class. See [[Containment]]. # Resource-like Can be declared only once. Must be unique to avoid conflicting parameter values.