-
Notifications
You must be signed in to change notification settings - Fork 21
External TLS cert/key not auto-updating for Hosted CE #471
Comments
Sounds good to me |
@brianhlin thoughts on how you want to proceed here? I see two paths..
|
I think I like option 2 and we can just set the following with updated paths:
If we do 2, though, are we going to be able to set the permissions on the cert/key properly? |
@brianhlin Ugh, yeah, I forgot about that whole problem. Thinking.. |
OK, will experiment and return with a PR! |
So I did a bit of looking and thinking on this one- We currently do the following:
As far as permissions are concerned, all of this is above board as far as I can tell. If we change the mount from
to
(or whatever, You can poke the filesystem and see files are properly created with the right mode (256 dec = 0400 oct) I made a nasty kubectl exec loop to just try to recursively look at /media while I waited between crashloops on my laziest/worst deployment of theHostedCE:
That looks like we ought to just be able to symlink to the right locations and things will be Fine (tm) ? |
We should be able to pick whatever, k8s should make the dir for us, IIRC. I think @matyasselmeci has used
We may need this to be world-readable. I forget exactly when the SchedD drops privs and if that's after it reads in the host cert. Otherwise I think This Is The Way so we'll have to make some minor adjustments to the container to create the symlinks if the certs live in whatever dir we choose. |
Works for me. Let's do that. We'll play along with whatever you guys have precedent for.
OK, so mode 432 instead of 256. (thanks Kubernetes for making this so intuitive and easy 💩 )
Sounds good. |
This is what I use in the condor containers:
|
@matyasselmeci - that probably should be executed every few hours, right? |
Yep. I don't have cron in the original htcondor images but in OSG images I put a call to it in /etc/cron.hourly. (It's part of the update-secrets script which also updates passwords and tokens.) |
Hi all! What's the next steps here? Not clear who's holding the ball on this. |
Container work here: https://opensciencegrid.atlassian.net/browse/SOFTWARE-4623. I believe @LincolnBryant is going to tackle the Helm Chart work. |
Indeed, I am trying to focus on this today/tomorrow and get this patch landed. Apologies for the slowness. |
PR #496 should be a very simple patch that should address this specific issue, if the container is updated appropriately. |
I noticed the following in the Kubernetes docs:
Unfortunately,
subPath
is exactly how we handle the mounting ofhostcert.pem
andhostkey.pem
. This means Let's Encrypt updates fromcert-manager
of the Secret does not propagate into the pod.I think potentially the best way to do this is to mount the secret in a separate directory, not use
subPath
, and then point the hosted CE configuration at these files.The text was updated successfully, but these errors were encountered: