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

Enhancement: Download oscap tailoring file from a private git repo #263

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

christophermay07
Copy link
Contributor

Purpose

This PR enhances the existing OpenSCAP step runner to allow for pulling down an OpenSCAP definition tailoring file from a private git repository.

Breaking?

No

Integration Testing

TBD; currently in progress

@christophermay07 christophermay07 requested review from itewk, dwinchell, twling and a team May 3, 2022 16:06
@christophermay07 christophermay07 added the enhancement New feature or request label May 3, 2022
@codecov
Copy link

codecov bot commented May 3, 2022

Codecov Report

Merging #263 (9d1aa4f) into main (bbc65e5) will not change coverage.
The diff coverage is 100.00%.

@@            Coverage Diff            @@
##              main      #263   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          106       106           
  Lines         4317      4334   +17     
=========================================
+ Hits          4317      4334   +17     
Flag Coverage Δ
pytests 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...unner/step_implementers/shared/openscap_generic.py 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@itewk
Copy link
Contributor

itewk commented May 3, 2022

The entire point of https://github.com/ploigos/ploigos-step-runner/blob/main/src/ploigos_step_runner/utils/file.py#L139 was to make it so we wouldn't have to have the "if file / if repo" logic all ovcer the palce, we could jsut have it in one place. so why not update https://github.com/ploigos/ploigos-step-runner/blob/main/src/ploigos_step_runner/utils/file.py#L139 to be able to take credentials and provide them to git if given so this logic isn't just in openscap but anywhere we need to pull a file?

@christophermay07 christophermay07 force-pushed the feature/oscap-rules-git-repo branch from 856d161 to fcb4b77 Compare May 24, 2022 14:26
@dwinchell
Copy link
Contributor

The entire point of https://github.com/ploigos/ploigos-step-runner/blob/main/src/ploigos_step_runner/utils/file.py#L139 was to make it so we wouldn't have to have the "if file / if repo" logic all ovcer the palce, we could jsut have it in one place. so why not update https://github.com/ploigos/ploigos-step-runner/blob/main/src/ploigos_step_runner/utils/file.py#L139 to be able to take credentials and provide them to git if given so this logic isn't just in openscap but anywhere we need to pull a file?

I agree this would be better. I'm also okay merging this because the work is already done but opening an issue to refactor it.

dwinchell
dwinchell previously approved these changes Nov 14, 2022
@christophermay07 christophermay07 changed the title DRAFT: Enhancement: Download oscap tailoring file from a private git repo Enhancement: Download oscap tailoring file from a private git repo Nov 16, 2022
@dwinchell
Copy link
Contributor

@christophermay07 based on our out of band conversation, i thought you were going to stop work on this (I may have misunderstood). I see more commits. Do you want me to review again instead?

@christophermay07
Copy link
Contributor Author

@christophermay07 based on our out of band conversation, i thought you were going to stop work on this (I may have misunderstood). I see more commits. Do you want me to review again instead?

@dwinchell since this PR was so old, I rebased again main to ensure that nothing merged recently caused any testing or linting conflicts with my existing PR. Rebase did not have any conflicts, so no need to review again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants