Skip to content

Commit

Permalink
Use pipx to install build dependencies on GHA runners (#370)
Browse files Browse the repository at this point in the history
* Install pip on build runners

* Fixing pip commands to be pipx

---------

Co-authored-by: alisonlhart <alhart@redhat.com>
  • Loading branch information
ssbarnea and alisonlhart authored Sep 17, 2024
1 parent 6c8702b commit a696a72
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions .github/actions/build-test/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ runs:
run: |
platform=${{ matrix.platform }}
echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
sudo apt install -y python3-pip python3-build pipx
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
Expand All @@ -37,7 +38,8 @@ runs:
shell: bash
id: ansible-builder-install
run: |
python3 -m pip install -U ansible-builder build
set -ex
python3 -m pipx install --force ansible-builder
python3 -m build --outdir final/dist/ --wheel
- name: Create a build context and Containerfile for base EE
Expand Down Expand Up @@ -83,14 +85,13 @@ runs:
- name: Squash image layers to save disk space
shell: bash
run: |
python3 -m pip install --upgrade docker-squash
python3 -m pipx install --force docker-squash
docker-squash ${{ inputs.namespace }}/${{ inputs.final_image }}:test
- name: Run tests against the container
shell: bash
run: |
python3 -m pip install --upgrade pip
python3 -m pip install --upgrade "tox>=4.0.0"
python3 -m pipx install --force "tox>=4.0.0"
tox -e test-image -- --container-engine docker --image-name ${{ inputs.namespace }}/${{ inputs.final_image }}:test
- name: Push the built image to ${{ inputs.registry }} by digest for ${{ matrix.platform }}
Expand Down

0 comments on commit a696a72

Please sign in to comment.