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

feat: update for regeneration features from trestlebot #30

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Component Definition Assemble
name: Component Definition Autofix
on:
workflow_call:
workflow_dispatch:
Expand All @@ -9,7 +9,7 @@ concurrency:

jobs:
auto-update:
name: Assemble compdef content
name: Autofix compdef content
runs-on: ubuntu-latest
permissions:
contents: write
Expand All @@ -18,12 +18,13 @@ jobs:
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
- name: Assemble-cd
id: assemble-cd
- name: Run trestlebot
id: autofix-cd
uses: RedHatProductSecurity/trestle-bot@main
with:
markdown_path: "markdown/components"
assemble_model: "compdef"
oscal_model: "compdef"
branch: ${{ github.head_ref }}
file_pattern: "*.json,markdown/*"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
24 changes: 13 additions & 11 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,19 @@ jobs:
permissions:
contents: read
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
- name: Clone
uses: actions/checkout@v3
with:
python-version: 3.8
- name: Install Trestle
run: make trestle-install
- name: Validate with Trestle
run: make validate
- name: Sanity check
run: make sanity-cd
ref: ${{ github.head_ref }}
- name: Check components
id: check-components
uses: RedHatProductSecurity/trestle-bot@main
with:
markdown_path: "markdown/components"
oscal_model: "profile"
check_only: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: CSV sanity check
run: make check-csv

Expand All @@ -34,4 +36,4 @@ jobs:
permissions:
contents: write
if: ${{ always() && contains(needs.*.result, 'failure') }}
uses: ./.github/workflows/assemble-cd.yml
uses: ./.github/workflows/autofix-cd.yml