onepassword-operator icon indicating copy to clipboard operation
onepassword-operator copied to clipboard

Better support for private keys

Open brizzbuzz opened this issue 1 year ago • 2 comments

Summary

Hi, I've been really enjoying most of the UX around storing secrets in 1Password and having the connector inject them into K8. However, one area that feels like it could use some more love is the need for storing and accessing private keys. Recently, while setting up a GitHub App, I found that attempting to store the private key as a "password" field was messing up the formatting of the key, leading to an error. The only solution I have found is to store the private key as a "text" field.

It's not the end of the world, but it would be nice to either

  1. Have a dedicated "private key" type field
  2. Allow for files attached to a secret to be uploaded to the K8 secret

This way, users could store their keys in a way that makes more sense than plaintext inside 1Password.

Use cases

See above

Is there a workaround to accomplish this today?

See above

brizzbuzz avatar Aug 21 '23 13:08 brizzbuzz

I experienced the same issue, and I have solved it with option 2 as that is already possible. Just add the private key as a file to the 1Password item, and it will end up in the k8s secret with the key as in 1Password and value the String contents of the file (without messing up the formatting).

This used to be in the documentation, but for some reason they removed almost all usable documentation starting in v1.7.1 and I have no idea where to find this now, but in the older docs you can see that files are supported https://github.com/1Password/onepassword-operator/tree/v1.7.0#usage

rhaex avatar Oct 12 '23 14:10 rhaex

I started to use https://external-secrets.io/ in combination with op-connect. This is much more configurable and easy to use.

mrclrchtr avatar Oct 12 '23 14:10 mrclrchtr