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

    Brian Schonecker

    01/11/2023, 7:33 PM
    I'll update it.
  • n

    natemccurdy

    01/11/2023, 7:33 PM
    The problem is that you're missing the
    >
    or
    |
    character after the yaml key's name.
  • n

    natemccurdy

    01/11/2023, 7:34 PM
    There are examples of how to do multiline encrypted yaml here: https://github.com/voxpupuli/hiera-eyaml#encrypting-multiline-valueshttps://github.com/voxpupuli/hiera-eyaml#encrypting-multiline-values
  • b

    Brian Schonecker

    01/11/2023, 7:42 PM
    Yeah, I've tried multiple permutations of those examples but I'm still getting unwanted indentation. I'm trying more stuff and will report back if I have success.
  • n

    natemccurdy

    01/11/2023, 7:52 PM
    I'd try starting from scratch, with just the private key file on disk formatted exactly how you expect. Then:
    Copy code
    eyaml encrypt -f <private_key>
    Copy the the output that uses the multi line syntax, then paste that into your Hiera data file, in a key that uses the
    >
    character. Put the encrypted contents on a new line, after the
    >
    , indenting by 2 spaces. For example:
    Copy code
    ---
    private_key_file: >
      ENC[PKCS7,MIIDTQYJKoZIhvcNAQcDoIIDPjCCAzoCAQAxggEhMIIBHQIBADAFMAACAQEw
      DQYJKoZIhvcNAQEBBQAEggEAXH7xB1xuzoMAqA/3jSXO0ZUR6+UCb3DsTTj3
      Lsrcx5oQBnJ/ml7GfBCPxBKfArZunLcnxmSk4hECKXdfgKsVjAa++JQWvtEm
      HUNTFqvwd76Ku+nMfI9c8g+X+l6obLjzWfJdg3t6Ja7CJKl8UNFtSmbfYKVi]
  • d

    Dr Bunsen Honeydew

    01/11/2023, 7:52 PM
    lsrcx5oqbnj/ml7gfbcpxbkfarzunlcnxmsk4heckxdfgksvjaa is on the rise! (Karma: 1)
  • d

    Dr Bunsen Honeydew

    01/11/2023, 7:52 PM
    ```- took a dive. (Karma: -96)
  • n

    natemccurdy

    01/11/2023, 7:53 PM
    I'd try starting from scratch, with just the private key file on disk formatted exactly how you expect. Then:
    Copy code
    eyaml encrypt -f <private_key>
    Copy the the output that uses the multi line syntax, then paste that into your Hiera data file, in a key that uses the
    >
    character. Put the encrypted contents on a new line, after the
    >
    , indenting by 2 spaces. For example:
    Copy code
    ---
    private_key_file: >
      ENC[PKCS7,MIIDTQYJKoZIhvcNAQcDoIIDPjCCAzoCAQAxggEhMIIBHQIBADAFMAACAQEw
      DQYJKoZIhvcNAQEBBQAEggEAXH7xB1xuzoMAqA/3jSXO0ZUR6+UCb3DsTTj3
      Lsrcx5oQBnJ/ml7GfBCPxBKfArZunLcnxmSk4hECKXdfgKsVjAa++JQWvtEm
      HUNTFqvwd76Ku+nMfI9c8g+X+l6obLjzWfJdg3t6Ja7CJKl8UNFtSmbfYKVi]
  • b

    Brian Schonecker

    01/11/2023, 7:57 PM
    Yep, I just did that. The resulting unencrypted yaml has some strange formatting. Openssl is complaining about the "BEGIN PRIVATE KEY" and "END PRIVATE KEY" stuff being indented. I'll try to eyaml encrypt just that stuff instead of the entire file.
  • l

    Lumiere

    01/11/2023, 8:26 PM
    how are you getting the data intoi something? because it should just be a file content =>
  • s

    Slackbot

    01/11/2023, 8:40 PM
    This message was deleted.
    t
    • 2
    • 2
  • k

    kenyon

    01/11/2023, 9:58 PM
    the strange formatting reminds me of https://github.com/voxpupuli/hiera-eyaml/issues/219
  • k

    kenyon

    01/11/2023, 9:58 PM
    the strange formatting sounds like https://github.com/voxpupuli/hiera-eyaml/issues/219
  • k

    kenyon

    01/11/2023, 10:04 PM
    the strange formatting reminds me of https://github.com/voxpupuli/hiera-eyaml/issues/219
  • s

    Slackbot

    01/12/2023, 5:06 AM
    This message was deleted.
    n
    • 2
    • 1
  • n

    Neeloj

    01/12/2023, 8:57 AM
    @vchepkov thank you for your suggestion, you mean I should create the systemd timer via puppet ?
  • n

    Neeloj

    01/12/2023, 9:51 AM
    Hi all, before i could do something like:
    puppet apply test.pp --ordering random
    why i cannot do that with the new version? does anyone know how can I do that with new version ?
    puppet apply --help | less
    doesnt help my alot. puppet version is 7.21.0. thank you all
  • b

    bastelfreak

    01/12/2023, 10:38 AM
    Are there any plans for Ubuntu 22 puppetserver packages? https://tickets.puppetlabs.com/browse/SERVER-3193
    👍 1
    🤔 1
  • s

    Slackbot

    01/12/2023, 11:32 AM
    This message was deleted.
    t
    k
    • 3
    • 5
  • m

    Michael Kelly

    01/12/2023, 11:34 AM
    Revisiting this from a different perspective. What about putting 2+ CA servers behind a HAProxy configured in active/passive mode? Alternatively, what if I create additional SRV records (with different weights/priorities) for the CA servers? The CA servers would use a shared filesystem to store the CA related files. The objective here is to avoid a situation where CA requests from two agents get routed to different CAs at the same time.
  • b

    bastelfreak

    01/12/2023, 11:47 AM
    I would go with https://github.com/fervidus/puppet_ca_utils or sync the CA files between to systems, but I wouldn't use a shared filesystem. that adds a lot of complexity but you don't gain much from it
  • d

    Dr Bunsen Honeydew

    01/12/2023, 12:45 PM
    kermit typing 🧑‍🏫Puppet Forge is about to start up in #CFD8Z9A4T
  • s

    Slackbot

    01/12/2023, 12:50 PM
    This message was deleted.
    b
    a
    • 3
    • 4
  • s

    Slackbot

    01/12/2023, 5:02 PM
    This message was deleted.
    b
    b
    +3
    • 6
    • 21
  • b

    bastelfreak

    01/12/2023, 5:09 PM
    also check https://github.com/mrwilson/mrwilson-multipkg
  • s

    Slackbot

    01/12/2023, 5:40 PM
    This message was deleted.
    j
    • 2
    • 3
  • j

    jms1

    01/12/2023, 5:44 PM
    dumb question, and i'm sure the answer is already out there and google is just being stupid today ... when configuring a service like apache/nginx, you need to do a "restart" when the service's config files change, but when the SSL key/cert files are updated you can do a restart, but should do a "reload" in order to not "hang up on" existing long-lived client connections ... the only two ways i've found to deal with this are (1) restart anyway, causing a flood of re-connects (the clients each have a long-lived websocket connection) and (2) an ugly hack involving an exec that usually works but not always, and which i'd like to get rid of, partly because if both the config and the SSL key/cert are updated at the same time, it restarts the service and then runs the exec ... can somebody point me to an example of a better way to handle this? at the very least, a way to "only run the exec if the service isn't also being told to restart"?
  • v

    vchepkov

    01/12/2023, 6:12 PM
    I think you can provide restart command to the service, which will reload it , instead of restarting
  • j

    jms1

    01/12/2023, 6:20 PM
    that's what i'm doing in the
    exec
    ... the puppet language has the
    notify
    meta-parameter which makes the resource (1) "execute" before the target, and (2) send a "restart" signal to the target if the resource was updated ... is there something like this, but which sends a "reload" signal instead?
  • c

    CVQuesty

    01/12/2023, 6:41 PM
    Does your init script have a reload option? Puppet talks directly to the init system
1...267268269...428Latest