Skip to content
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

[vdk-kerberos-auth] Fix keytab file in job directory #721

Merged
merged 1 commit into from
Feb 21, 2022

Conversation

doks5
Copy link
Contributor

@doks5 doks5 commented Feb 21, 2022

Currently, if a VDK_KEYTAB_FOLDER is not specified, the kerberos plugin
looks for the keytab file in the data job directory, which causes operation
conflict between the vdk run and vdk deploy commands.

vdk run looks for the keytab file in the job's directory and throws an exception
if the file is not there, while
vdk deploy checks that there IS NO keytab file in the job's directory, and throws
an exception if there is such a file in the directory.

This change ensures that if VDK_KEYTAB_FOLDER is not set, the default directory to
look for a keytab file would be the data job's parent directory.

Testing Done: moved the keytab file used in functional tests outside the test job directory.

Signed-off-by: Andon Andonov [email protected]

Copy link
Contributor

@gabrielgeorgiev1 gabrielgeorgiev1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You may want to review any jobs which use keytab files and make sure that their keytab is located outside the job directory. This includes non-github repos as well (I have some memory where I placed a test job's keytab inside the job dir, this is why I'm mentioning this).

@doks5 doks5 force-pushed the person/andonova/keytabfile-bug branch 3 times, most recently from 82deacb to ed17798 Compare February 21, 2022 13:28
Currently, if a `VDK_KEYTAB_FOLDER` is not specified, the kerberos plugin
looks for the keytab file in the data job directory, which causes operation
conflict between the `vdk run` and `vdk deploy` commands.

`vdk run` looks for the keytab file in the job's directory and throws an exception
if the file is not there, while
`vdk deploy` checks that there IS NO keytab file in the job's directory, and throws
an exception if there is such a file in the directory.

This change ensures that if `VDK_KEYTAB_FOLDER` is not set, the default directory to
look for a keytab file would be the data job's parent directory.

Testing Done: moved the keytab file used in functional tests outside the test job directory.

Signed-off-by: Andon Andonov <[email protected]>
@doks5 doks5 force-pushed the person/andonova/keytabfile-bug branch from ed17798 to f57c38c Compare February 21, 2022 13:40
@doks5 doks5 merged commit 4aaeb2e into main Feb 21, 2022
@doks5 doks5 deleted the person/andonova/keytabfile-bug branch February 21, 2022 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants