https://www.puppet.com/community logo
Join Slack
Powered by
# puppet
  • m

    Mihai

    02/01/2023, 11:11 AM
    i am having a couple of issues after the SSL certificate for the PuppetDB expired a few days ago
  • m

    Mihai

    02/01/2023, 11:11 AM
    Agents cannot pull the latest catalogue from the master and the puppet board cannot connect to the puppetdb
  • m

    Mihai

    02/01/2023, 11:11 AM
    https://paste.centos.org/view/aee86fb2
  • m

    Mihai

    02/01/2023, 11:13 AM
    I am not the one who set up the current puppet config, it was setup about 8-9 years ago by a developer with a YAML based hiera backend
  • m

    Mihai

    02/01/2023, 11:14 AM
    I have recreated the puppetdb ssl certificate on the master, i've also recreated the master ssl certificate and CA certificate as well
  • m

    Mihai

    02/01/2023, 11:14 AM
    i am having a couple of issues after the SSL certificate for the PuppetDB expired a few days ago
  • m

    Mihai

    02/01/2023, 11:15 AM
    It looks as if the agents and the puppet board cannot talk to the puppetdb
  • s

    Slackbot

    02/01/2023, 11:15 AM
    This message was deleted.
    b
    m
    • 3
    • 3
  • s

    Slackbot

    02/01/2023, 11:17 AM
    This message was deleted.
    y
    c
    h
    • 4
    • 39
  • c

    canihavethisone

    02/01/2023, 11:19 AM
    Does anyone know how to check if a variable (string) is in an array AND check that case (upper/lower) matches? I am using the example below, and the 'if !($K in $valid_sections)` part is ignoring case completely. THANKS in advance!
    Copy code
    if !($k in $valid_sections) {
            fail("Invalid section '${k}' in '${key}' hash")
          }
  • c

    canihavethisone

    02/01/2023, 11:19 AM
    Does anyone know how to check if a variable (string) is in an array AND check that case (upper/lower) matches? I am using the example below, and the 'if !($K in $valid_sections)` part is ignoring case completely. THANKS in advance!
    Copy code
    if !($k in $valid_sections) {
            fail("Invalid section '${k}' in '${key}' array")
          }
  • h

    helindbe

    02/01/2023, 12:31 PM
    message has been deleted
  • y

    Yury Bushmelev

    02/01/2023, 12:54 PM
    The topicstarter needs it, yes
  • s

    Slackbot

    02/01/2023, 12:58 PM
    This message was deleted.
    b
    b
    • 3
    • 4
  • b

    Brian Schonecker

    02/01/2023, 1:02 PM
    I just found these parameters which may help me.
  • s

    Slackbot

    02/01/2023, 1:19 PM
    This message was deleted.
    b
    b
    • 3
    • 5
  • b

    BAlcorn

    02/01/2023, 1:32 PM
    Complex question. We have custom facts that determine "appgroup" and "authorization". With RHEL 9 our authorization schema is changing, so I need to break it off into a separate yaml file, which I've done.
    facter-p authorization
    returns gaig_users_9 as expected; however, when I run puppet agent -t that yaml file isn't being processed. See pic for hiera setup Secondly, I'm declaring a second class in the init.pp for our gaig_users module (code snipped below). I don't know if perhaps this is what I'm doing wrong, and would appreciate anyone's input
    Copy code
    class gaig_users_ldap::sssd (
      Optional[String[1]] $simple_allow_user_list = undef,
    ) {
      package { 'sssd-client':
        ensure => 'present',
      }
      service { 'sssd':
        ensure  => 'running',
        require => Package['sssd-client'],
      }
      $simple_allow_users = $gaig_users_ldap::sssd::simple_allow_user_list
      file_line { 'sssd.conf for simple_allow_users':
        ensure  => present,
        path    => '/etc/sssd/sssd.conf',
        line    => "simple_allow_users = ${simple_allow_users}",
        match   => '^simple_allow_users',
        notify  => Service['sssd'],
        require => Package['sssd-client'],
      }
      $ldap_user_defaults = {
        ensure     => present,
        membership => 'inclusive',
      }
      create_resources('user', hiera_hash(ldap_users), $ldap_user_defaults)
    }
    I'm certain it worked at least once a few weeks ago, but since then, it's been a dead end.
  • s

    Slackbot

    02/01/2023, 2:44 PM
    This message was deleted.
    s
    • 2
    • 1
  • s

    Slackbot

    02/01/2023, 2:45 PM
    This message was deleted.
    šŸ‘ 1
    n
    • 2
    • 1
  • s

    sheikh

    02/01/2023, 2:48 PM
    Hello out there simple question, new to puppet world! I would like to verify lines, if not present deploy lines at the end in the config file. I have to check following lines in the location : /etc/screenrc
    Copy code
    bindkey "^D" echo 'Blocked. Please use [Ctrl]+[A] + [Ctrl]+[Enter] + [Y]'
    bind "^M" quit
    Copy code
    file {'/etc/screenrc':
        ensure => 'file',
      }
      file_line {'':
        path    => '/etc/screenrc',
        line    => '',
        require => File['/etc/screenrc'],
      }
  • s

    sheikh

    02/01/2023, 2:49 PM
    Hello out there simple question, new to puppet world! I would like to verify lines, if not present deploy lines at the end in the config file. I have to check following lines in the location : /etc/screenrc
    Copy code
    bindkey "^D" echo 'Blocked. Please use [Ctrl]+[A] + [Ctrl]+[Enter] + [Y]'
    bind "^M" quit
    How to adopt in below manifest file or any different way? Thanks
    Copy code
    file {'/etc/screenrc':
        ensure => 'file',
      }
      file_line {'':
        path    => '/etc/screenrc',
        line    => '',
        require => File['/etc/screenrc'],
      }
  • c

    Corporate Gadfly

    02/01/2023, 3:04 PM
    @Sergei G.: Since puppet is not a monitoring system and I don't care about ephemeral facts, I have the following in `/etc/puppetlabs/facter/facter.conf`:
    Copy code
    facts : {
      blocklist : [
        "file system",
        "load_averages",
        "identity",
        "memory.system.capacity",
        "memory.system.used*",
        "memory.system.available*",
        "memory.swap.capacity",
        "memory.swap.used*",
        "memory.swap.available*",
        "system_uptime",
      ]
    }
    Hope that helps.
  • b

    Brian Schonecker

    02/01/2023, 3:15 PM
    That's a very helpful document. I wasn't aware of the beware of source behavior.
    šŸ‘šŸ¼ 1
    šŸ‘€ 1
    āœ”ļø 1
    šŸ‘ 1
  • c

    Corporate Gadfly

    02/01/2023, 3:19 PM
    @Sergei G.: Since puppet is not a monitoring system and I don't care about ephemeral facts, I have the following in
    /etc/puppetlabs/facter/facter.conf
    to block unwanted facts:
    Copy code
    facts : {
      blocklist : [
        "file system",
        "load_averages",
        "identity",
        "memory.system.capacity",
        "memory.system.used*",
        "memory.system.available*",
        "memory.swap.capacity",
        "memory.swap.used*",
        "memory.swap.available*",
        "system_uptime",
      ]
    }
    Hope that helps.
  • v

    vchepkov

    02/01/2023, 3:40 PM
    would be nice to be able to block based on a pattern
    Copy code
    mountpoints./run*
  • s

    Slackbot

    02/01/2023, 4:20 PM
    This message was deleted.
    b
    b
    +3
    • 6
    • 20
  • b

    Brian Schonecker

    02/01/2023, 4:22 PM
    I've been tasked with rotating ssh keys for a service account on my linux servers. I am considering using Puppet to manage the ~/.ssh/authorized_keys and the pub/private keys (exported resources?) for the service account(s) rsa/ecdsa and dsa keys. I thought about using $fqdn_rand to pseudo randomize the keys and use the integer-based month as a seed to further randomize the key generation. Every month, I'll rotate one key (rsa, for example) and then the next month rotate the ecdsa/dsa keys so that there is less of a chance of me locking out the service account. At the same time, the authorized_keys file will be updated with the old key(s) deleted and the new key(s) added. Is there a better way to rotate the keys with Puppet or other not-too-expensive utility? I've used Cyberark to rotate passwords and SSH keys but that is cost prohibitive for this project. Feedback appreciated.
  • s

    spin

    02/01/2023, 5:03 PM
    ahh i see im not alone in hitting this.. anyone seen an update?
  • b

    bastelfreak

    02/01/2023, 5:08 PM
    we have a module to create keys https://github.com/voxpupuli/puppet-ssh_keygen
  • b

    Brian Schonecker

    02/01/2023, 5:09 PM
    The module only creates the keys.
1...292293294...428Latest