Skip to content

Commit 1c7cf34

Browse files
chore: update RL scanner to use centralized devsecops-tooling action (#105)
* chore: update RL scanner to use centralized devsecops-tooling action Replace the old rl-scanner reusable workflow and local composite action with an inline job in publish.yml using auth0/devsecops-tooling rl-scan. * update poetry.lock file
1 parent 69a018d commit 1c7cf34

4 files changed

Lines changed: 809 additions & 538 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: 45 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,31 +3,60 @@ name: Publish Release
33
on:
44
workflow_dispatch:
55

6-
### TODO: Replace instances of './.github/actions/' with reference to the `dx-sdk-actions` repo is made public and this file is transferred over
7-
### TODO: Also remove `get-prerelease`, `get-version`, `release-create`, `tag-create` and `tag-exists` actions from this repo's .github/actions folder once the repo is public.
8-
96
permissions:
107
contents: write
118
id-token: write # Required for trusted publishing to PyPI
129

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

3362
steps:

.github/workflows/rl-scanner.yml

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

0 commit comments

Comments
 (0)