-
Notifications
You must be signed in to change notification settings - Fork 714
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 an oscal directory and GitHub Actions workflow for upstream OSCAL content #11286
Merged
Merged
Changes from 3 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
5b30405
feat(action): adds directory and action for vendor dir
jpower432 dd6de8b
fix: incorporates PR feedback on update-vendor.yml and directory loca…
jpower432 2a25d6d
Updates update-oscal to use variables for references in the repositories
jpower432 6d2aa19
Converts the README under shared/references/oscal to Markdown
jpower432 8e0b2ae
Updates the PR body message in update-oscal.yml
jpower432 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
name: Update vendored OSCAL content | ||
|
||
on: | ||
workflow_dispatch: | ||
schedule: | ||
# Run weekly at 05:00 on Sunday | ||
- cron: "0 5 * * 0" | ||
env: | ||
NIST_REPO_REF: "690f517daaf3a6cbb4056d3cde6eae2756765620" | ||
FEDRAMP_REPO_REF: "master" | ||
|
||
jobs: | ||
update-oscal: | ||
name: Update content | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
pull-requests: write | ||
strategy: | ||
matrix: | ||
variables: | ||
- catalog-source: "https://raw.githubusercontent.com/usnistgov/oscal-content/${NIST_REPO_REF}/nist.gov/SP800-53/rev5/json/NIST_SP-800-53_rev5_catalog.json" | ||
profile-source: "https://raw.githubusercontent.com/GSA/fedramp-automation/${FEDRAMP_REPO_REF}/dist/content/rev5/baselines/json/FedRAMP_rev5_HIGH-baseline_profile.json" | ||
profile-name: "fedramp_rev5_high" | ||
catalog-name: "nist_rev5_800_53" | ||
- catalog-source: "https://raw.githubusercontent.com/usnistgov/oscal-content/${NIST_REPO_REF}/nist.gov/SP800-53/rev4/json/NIST_SP-800-53_rev4_catalog.json" | ||
profile-source: "https://raw.githubusercontent.com/GSA/fedramp-automation/${FEDRAMP_REPO_REF}/dist/content/rev4/baselines/json/FedRAMP_rev4_HIGH-baseline_profile.json" | ||
profile-name: "fedramp_rev4_high" | ||
catalog-name: "nist_rev4_800_53" | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Install Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: '3.9' | ||
- name: Install python deps | ||
run: pip3 install requests compliance-trestle==2.4.0 | ||
- name: Update catalogs | ||
run: | | ||
rm -rf "catalogs/${{ matrix.variables.catalog-name }}" | ||
trestle import -f "${{ matrix.variables.catalog-source }}" -o "${{ matrix.variables.catalog-name }}" | ||
working-directory: ./shared/references/oscal | ||
- name: Update profiles | ||
run: | | ||
rm -rf "profiles/${{ matrix.variables.profile-name }}" | ||
trestle import -f "${{ matrix.variables.profile-source }}" -o "${{ matrix.variables.profile-name }}" | ||
trestle href --name "${{ matrix.variables.profile-name }}" -hr "trestle://catalogs/${{ matrix.variables.catalog-name }}/catalog.json" | ||
working-directory: ./shared/references/oscal | ||
- name: Update content | ||
uses: peter-evans/[email protected] | ||
with: | ||
base: master | ||
branch: "oscal-update-${{ github.run_id }}" | ||
delete-branch: true | ||
commit-message: "Update OSCAL content in shared/references/oscal" | ||
title: "Update upstream OSCAL content from usnistogv and GSA" | ||
body: | | ||
Updates upstream OSCAL content | ||
- usnistgov NIST 800-53 from "${{ matrix.variables.catalog-source }}" | ||
- GSA FedRAMP OSCAL profiles from "${{ matrix.variables.profile-source }}" | ||
|
||
Auto-generated by [create-pull-request](https://github.com/peter-evans/create-pull-request) GitHub action | ||
add-paths: | | ||
shared/references/oscal/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# trestle config file |
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Per the style guide please use Markdown unless there is a compelling reason. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I missed that detail in the guide. I will convert to Markdown. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
= OSCAL Content | ||
|
||
This `oscal` directory contains a link:https://ibm.github.io/compliance-trestle/[compliance-trestle] managed workspace to import upstream catalog and profile content into generated link:https://pages.nist.gov/OSCAL-Reference/models/v1.1.1/component-definition/json-outline/[OSCAL Component Definition]. | ||
|
||
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Could you also provide the path to this GitHub Actions file as well?