Skip to content

Commit

Permalink
Fix KPOps action to get package from testPyPI (#396)
Browse files Browse the repository at this point in the history
  • Loading branch information
raminqaf authored Dec 22, 2023
1 parent 96c196f commit 3cd1095
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 15 deletions.
7 changes: 6 additions & 1 deletion action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,12 @@ runs:
shell: bash
run: |
echo "::group::install kpops package"
pip install -r "${{ steps.requirements.outputs.path }}"
# Check if kpops-version contains ".dev"
if [[ "${{ inputs.kpops-version }}" == *".dev"* ]]; then
pip install -r "${{ steps.requirements.outputs.path }}" -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/
else
pip install -r "${{ steps.requirements.outputs.path }}"
fi
echo "::endgroup::"
- name: ${{ inputs.command }} ${{ inputs.pipeline }} pipeline
Expand Down
16 changes: 2 additions & 14 deletions docs/docs/user/references/ci-integration/github-actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,25 +33,13 @@ steps:
pipeline: pipelines/my-pipeline-file.yaml
kpops-version: 1.2.3

# It is possible to use a pre-release KPOps version from TestPyPI https://test.pypi.org/project/kpops/#history
- name: Deploy Kafka pipeline
uses: bakdata/kpops@main
with:
command: deploy --execute
working-directory: home/my-kpops-root-dir
pipeline: pipelines/my-pipeline-file.yaml
kpops-version: 1.2.3
kpops-version: 1.2.5.dev20230707132709
# ...
```

It is possible to use a pre-release KPOps version from [TestPyPI](https://test.pypi.org/project/kpops/#history).

```yaml
steps:
- name: Deploy Kafka pipeline
uses: bakdata/kpops@main
with:
command: deploy --execute
working-directory: home/my-kpops-root-dir
pipeline: pipelines/my-pipeline-file.yaml
kpops-version: 1.2.5.dev20230707132709 -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/
```

0 comments on commit 3cd1095

Please sign in to comment.