Skip to content

Commit 360322a

Browse files
chore: migrate RL scanner to shared devsecops-tooling action (#837)
Migrates the RL scanner from the repo-local workflow + composite action to the shared `auth0/devsecops-tooling/.github/actions/rl-scan@main` action. **Changes:** - Replace the old `rl-scanner.yml` reusable workflow and `.github/actions/rl-scanner` composite action with a single inline job using the shared action - Wire `publish-pypi` to depend on `rl-scanner` via `needs:` Related: auth0/auth0-api-python#89
1 parent dccf7ae commit 360322a

3 files changed

Lines changed: 43 additions & 165 deletions

File tree

.github/actions/rl-scanner/action.yml

Lines changed: 0 additions & 71 deletions
This file was deleted.

.github/workflows/publish.yml

Lines changed: 43 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,49 @@ permissions:
1212

1313
jobs:
1414
rl-scanner:
15-
uses: ./.github/workflows/rl-scanner.yml
16-
with:
17-
python-version: "3.10"
18-
artifact-name: "auth0-python.tgz"
19-
secrets:
20-
RLSECURE_LICENSE: ${{ secrets.RLSECURE_LICENSE }}
21-
RLSECURE_SITE_KEY: ${{ secrets.RLSECURE_SITE_KEY }}
22-
SIGNAL_HANDLER_TOKEN: ${{ secrets.SIGNAL_HANDLER_TOKEN }}
23-
PRODSEC_TOOLS_USER: ${{ secrets.PRODSEC_TOOLS_USER }}
24-
PRODSEC_TOOLS_TOKEN: ${{ secrets.PRODSEC_TOOLS_TOKEN }}
25-
PRODSEC_TOOLS_ARN: ${{ secrets.PRODSEC_TOOLS_ARN }}
15+
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && github.event.pull_request.merged && startsWith(github.event.pull_request.head.ref, 'release/'))
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: actions/checkout@v5
19+
with:
20+
fetch-depth: 0
21+
fetch-tags: true
22+
23+
- name: Configure Python
24+
uses: actions/setup-python@v6
25+
with:
26+
python-version: "3.12"
27+
28+
- name: Build artifact
29+
run: |
30+
pip install --user --upgrade pip
31+
pip install --user pipx
32+
pipx ensurepath
33+
pipx install poetry
34+
poetry config virtualenvs.in-project true
35+
poetry install --with dev
36+
poetry build
37+
tar -czvf auth0-python.tgz *
38+
39+
- name: Get version
40+
id: get_version
41+
uses: ./.github/actions/get-version
42+
43+
- name: Run RL Scanner
44+
uses: auth0/devsecops-tooling/.github/actions/rl-scan@main
45+
with:
46+
artifact-name: "auth0-python"
47+
artifact-path: "${{ github.workspace }}/auth0-python.tgz"
48+
version: ${{ steps.get_version.outputs.version }}
49+
RLSECURE_LICENSE: ${{ secrets.RLSECURE_LICENSE }}
50+
RLSECURE_SITE_KEY: ${{ secrets.RLSECURE_SITE_KEY }}
51+
SIGNAL_HANDLER_TOKEN: ${{ secrets.SIGNAL_HANDLER_TOKEN }}
52+
SIGNAL_HANDLER_DOMAIN: ${{ secrets.SIGNAL_HANDLER_DOMAIN }}
53+
PRODSEC_TOOLS_ARN: ${{ secrets.PRODSEC_TOOLS_ARN }}
54+
PRODSEC_TOOLS_USER: ${{ secrets.PRODSEC_TOOLS_USER }}
55+
PRODSEC_TOOLS_TOKEN: ${{ secrets.PRODSEC_TOOLS_TOKEN }}
56+
PRODSEC_PYTHON_TOOLS_REPO: ${{ secrets.PRODSEC_PYTHON_TOOLS_REPO }}
57+
2658
publish-pypi:
2759
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && github.event.pull_request.merged && startsWith(github.event.pull_request.head.ref, 'release/'))
2860
name: "PyPI"

.github/workflows/rl-scanner.yml

Lines changed: 0 additions & 83 deletions
This file was deleted.

0 commit comments

Comments
 (0)