Skip to content

Commit

Permalink
PYTHON-4388 [v4.8] Fix dist handling in SSDLC workflow (#1706)
Browse files Browse the repository at this point in the history
  • Loading branch information
blink1073 authored Jun 25, 2024
1 parent 94de52a commit 14ed482
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .github/workflows/dist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ on:
workflow_dispatch:
pull_request:
workflow_call:
inputs:
ref:
required: true
type: string

concurrency:
group: dist-${{ github.ref }}
Expand Down Expand Up @@ -44,6 +48,7 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ inputs.ref }}

- uses: actions/setup-python@v5
with:
Expand Down Expand Up @@ -99,6 +104,7 @@ jobs:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ inputs.ref }}

- uses: actions/setup-python@v5
with:
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/release-python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ jobs:
permissions:
id-token: write
contents: write
outputs:
version: ${{ steps.pre-publish.outputs.version }}
steps:
- uses: mongodb-labs/drivers-github-tools/secure-checkout@v2
with:
Expand All @@ -44,19 +46,22 @@ jobs:
aws_secret_id: ${{ secrets.AWS_SECRET_ID }}
artifactory_username: ${{ vars.ARTIFACTORY_USERNAME }}
- uses: mongodb-labs/drivers-github-tools/python/pre-publish@v2
id: pre-publish
with:
version: ${{ inputs.version }}
dry_run: ${{ inputs.dry_run }}

build-dist:
needs: [pre-publish]
uses: ./.github/workflows/dist.yml
with:
ref: ${{ needs.pre-publish.outputs.version }}

static-scan:
needs: [pre-publish]
uses: ./.github/workflows/codeql.yml
with:
ref: ${{ github.ref }}
ref: ${{ needs.pre-publish.outputs.version }}

publish:
needs: [build-dist, static-scan]
Expand Down

0 comments on commit 14ed482

Please sign in to comment.