binford2k
08/04/2022, 10:46 PMpuppet lookup profile::stream_web::configPatrick Rynhart
08/04/2022, 10:46 PMNotice: {developmentb => {someattribute => here, anotherattribute => here}}Patrick Rynhart
08/04/2022, 10:46 PMNotice: {developmentc => {someattribute => here, anotherattribute => here}}binford2k
08/04/2022, 10:47 PMbinford2k
08/04/2022, 10:47 PMPatrick Rynhart
08/04/2022, 10:47 PMPatrick Rynhart
08/04/2022, 10:48 PMnatemccurdy
08/04/2022, 10:51 PMeach loop, so that Puppet validates that each element matches that data type.vchepkov
08/04/2022, 10:53 PMprofile::stream_web::config:
developmentb:
someattribute: 'here'
anotherattribute: 'here'
developmentc:
someattribute: 'here'
anotherattribute: 'here'
config.each | $deployment, $attrs | {
notify { "${deployment}: someattribute: ${attr['someattribute']}": }
}natemccurdy
08/04/2022, 10:53 PMdevelopmentb, not someattributebinford2k
08/04/2022, 10:53 PMbinford2k
08/04/2022, 10:54 PMPatrick Rynhart
08/04/2022, 10:54 PMbinford2k
08/04/2022, 10:54 PMPatrick Rynhart
08/04/2022, 10:54 PMvchepkov
08/04/2022, 10:54 PMprofile::stream_web::config:
developmentb:
someattribute: 'here'
anotherattribute: 'here'
developmentc:
someattribute: 'here'
anotherattribute: 'here'
config.each | $deployment, $attrs | {
notify { "${deployment}: someattribute: ${attr['someattribute']}": }
}helindbe
08/04/2022, 10:55 PMhelindbe
08/04/2022, 10:59 PMbinford2k
08/04/2022, 11:00 PMPatrick Rynhart
08/04/2022, 11:02 PMPatrick Rynhart
08/04/2022, 11:02 PMprofile::stream_web::config:
muc:
'developmentb':
someattribute: 'here'
anotherattribute: 'here'
'developmentc':
someattribute: 'here'
anotherattribute: 'here'Patrick Rynhart
08/04/2022, 11:02 PMPatrick Rynhart
08/04/2022, 11:02 PMclass profile::stream_web (
$config = [],
) {
$muc = $config['muc']
$muc.each | $value | {
$d1 = $value['someattribute']
notify { "$d1": }
}vchepkov
08/04/2022, 11:02 PMPatrick Rynhart
08/04/2022, 11:03 PMSlackbot
08/04/2022, 11:04 PMbinford2k
08/04/2022, 11:05 PMbinford2k
08/04/2022, 11:05 PMbinford2k
08/04/2022, 11:06 PMbinford2k
08/04/2022, 11:06 PM