-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds creation of sentinel files for checking provider status #450
Conversation
13ea6db
to
1ea9dee
Compare
3989326
to
9872fe1
Compare
9872fe1
to
3ec40b7
Compare
794e46d
to
bbe315f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking forward to the walk through. Here are a few initial minor comments.
bbe315f
to
5ba8969
Compare
5ba8969
to
5ed806a
Compare
Code Climate has analyzed commit 5ed806a and detected 0 issues on this pull request. The test coverage on the diff in this pull request is 85.9% (50% is the threshold). This pull request will bring the total coverage in the repository to 89.8% (-0.2% change). View more on Code Climate. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Desired Outcome
/conjur/status/CONJUR_SECRETS_PROVIDED
, but this can be mounted by an application container via a shared volume mount at any arbitrary location in the container's file system./conjur/status/CONJUR_SECRETS_UPDATED
, but this can be mounted by an application container via a shared volume mount at any arbitrary location in the container's file system./usr/local/bin/conjur_secrets_provided
that waits for the.../CONJUR_SECRETS_PROVIDED
to be created. This can be used in apostStart
lifecycle hook definition for the SP container, to defer startup of app container until SP has completed its first round of providing secrets..../CONJUR_SECRETS_UPDATED
file to/conjur/status/conjur_secrets_unchanged
. This script returns a non-zero exit status whenever secret files or Kubernetes Secrets have changed. This can be used in alivenessProbe
orreadinessProbe
definition for an application container to force Kubernetes/kubelet to restart this container when secrets have been updated. The Deployment manifest would need to include avolumeMount
to mount this directory/file in the application container, along with thelivenessProbe
/readinessProbe
definition.With the above changes, a
postStart
lifecycle hook for the Secrets Provider container would look like this:And a
livenessProbe
for an application container that would serve as a "file watcher" can potentially look something like this (assuming thelivenessProbe
is not already being used by the container as a health probe):Where the application container (and SP container) would need to include volumeMounts similar to this:
and the Pod would need a Volume defined:
Implemented Changes
/conjur/status/CONJUR_SECRETS_PROVIDED
file after initial round of providing secrets./conjur/status/CONJUR_SECRETS_UPDATED
file whenever secret files or Kubernetes Secrets have been updated**.conjur_secrets_unchanged
script to/conjur/status
in it file system. This directory can be volume mounted by the application container at any arbitrary path in the application container's file system.pkt/secrets
. Provider configuration was split up into separate embedded structs for:.../CONJUR_SECRETS_UPDATED
file when appropriate.Connected Issue/Story
CyberArk internal issue link: ONYX-17885
Definition of Done
Changelog
CHANGELOG update
Test coverage
changes, or
Documentation
README
s) were updated in this PRBehavior
Security