Skip to content

RHEL 10 HIPAA Profile Updates #765

RHEL 10 HIPAA Profile Updates

RHEL 10 HIPAA Profile Updates #765

---
name: Gate / Kubernetes Test Content Parsing
on:
pull_request:
types:
- opened
- reopened
- synchronize
concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.run_id }}
cancel-in-progress: true
jobs:
datastream-parsing:
name: XCCDF Datastream parsing
runs-on: ubuntu-latest
steps:
- name: Copy XCCDF files from existing content image
uses: nick-fields/retry@7152eba30c6575329ac0576536151aca5a72780e # v3
with:
timeout_minutes: 20
max_attempts: 3
retry_wait_seconds: 300
retry_on: error
command: |
mkdir -p content
docker pull ghcr.io/complianceascode/k8scontent:${{ github.event.number }}
docker run --rm -v $PWD/content:/content:z ghcr.io/complianceascode/k8scontent:${{ github.event.number }} bash -c "cp *.xml /content"
- name: Clone compliance operator repository
run: |
git clone https://github.com/ComplianceAsCode/compliance-operator.git
- name: Fetch go version used in compliance-operator go.mod
run: |
cd compliance-operator
go mod edit -json | jq -r '.Go' > go-version
if [ ! -s go-version ]; then
echo "Failed to fetch go version from compliance-operator go.mod"
exit 1
fi
- name: Save go version to be used in setup-go action
id: save-go-version
run: |
echo "go-version=$(cat compliance-operator/go-version)" > compliance-operator/go-version
- uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5
with:
go-version: ${{ steps.save-go-version.outputs.go-version }}
- name: Run ginkgo tests and check if each XCCDF file is parsed correctly
run: |
export DEFAULT_CONTENT_DS_FILE_PATH=$PWD/content
cd compliance-operator
make test-datastreams