[rocprofiler-systems] Update containers workflow to not push on PR (#634)
* Change PUSH_COMMAND logic for debugging * Change to only push on non-PR events * Add separate steps for PR and non-PR events * Update .github/workflows/rocprofiler-systems-containers.yml Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Remove $ {{}} from if condition on steps * add github repository check for workflow
Este commit está contenido en:
@@ -26,6 +26,7 @@ env:
|
||||
|
||||
jobs:
|
||||
prepare_matrix_ci:
|
||||
if: github.repository == 'ROCm/rocm-systems'
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
matrix_data: ${{ steps.generate_matrix_ci.outputs.matrix_data }}
|
||||
@@ -69,7 +70,8 @@ jobs:
|
||||
username: ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }}
|
||||
password: ${{ secrets.ROCPROF_SYS_DOCKER_TOKEN }}
|
||||
|
||||
- name: Build CI Container
|
||||
- name: Build CI Container (PR - No Push)
|
||||
if: github.event_name == 'pull_request'
|
||||
timeout-minutes: 45
|
||||
uses: nick-fields/retry@v3
|
||||
with:
|
||||
@@ -78,12 +80,24 @@ jobs:
|
||||
max_attempts: 3
|
||||
command: |
|
||||
pushd projects/rocprofiler-systems/docker
|
||||
PUSH_COMMAND="--push"
|
||||
if [ ${{ github.event_name == 'pull_request' }} ]; then PUSH_COMMAND=""; fi
|
||||
./build-docker-ci.sh --distro ${{ matrix.distro }} --versions ${{ matrix.version }} --user ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }} ${PUSH_COMMAND} --jobs 2 --elfutils-version 0.188 --boost-version 1.79.0
|
||||
./build-docker-ci.sh --distro ${{ matrix.distro }} --versions ${{ matrix.version }} --user ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }} --jobs 2 --elfutils-version 0.188 --boost-version 1.79.0
|
||||
popd
|
||||
|
||||
- name: Build CI Container (Push)
|
||||
if: github.event_name != 'pull_request'
|
||||
timeout-minutes: 45
|
||||
uses: nick-fields/retry@v3
|
||||
with:
|
||||
retry_wait_seconds: 60
|
||||
timeout_minutes: 45
|
||||
max_attempts: 3
|
||||
command: |
|
||||
pushd projects/rocprofiler-systems/docker
|
||||
./build-docker-ci.sh --distro ${{ matrix.distro }} --versions ${{ matrix.version }} --user ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }} --push --jobs 2 --elfutils-version 0.188 --boost-version 1.79.0
|
||||
popd
|
||||
|
||||
prepare_matrix_release:
|
||||
if: github.repository == 'ROCm/rocm-systems'
|
||||
runs-on: ubuntu-latest
|
||||
outputs:
|
||||
matrix_data: ${{ steps.generate_matrix_release.outputs.matrix_data }}
|
||||
@@ -126,7 +140,8 @@ jobs:
|
||||
username: ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }}
|
||||
password: ${{ secrets.ROCPROF_SYS_DOCKER_TOKEN }}
|
||||
|
||||
- name: Build Base Container
|
||||
- name: Build Base Container (PR - No Push)
|
||||
if: github.event_name == 'pull_request'
|
||||
timeout-minutes: 45
|
||||
uses: nick-fields/retry@v3
|
||||
with:
|
||||
@@ -135,7 +150,18 @@ jobs:
|
||||
max_attempts: 3
|
||||
command: |
|
||||
pushd projects/rocprofiler-systems/docker
|
||||
PUSH_COMMAND="--push"
|
||||
if [ ${{ github.event_name == 'pull_request' }} ]; then PUSH_COMMAND=""; fi
|
||||
./build-docker.sh --distro ${{ matrix.os-distro }} --versions ${{ matrix.os-version }} --rocm-versions ${{ matrix.rocm-version }} --user ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }} ${PUSH_COMMAND}
|
||||
./build-docker.sh --distro ${{ matrix.os-distro }} --versions ${{ matrix.os-version }} --rocm-versions ${{ matrix.rocm-version }} --user ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }}
|
||||
popd
|
||||
|
||||
- name: Build Base Container (Push)
|
||||
if: github.event_name != 'pull_request'
|
||||
timeout-minutes: 45
|
||||
uses: nick-fields/retry@v3
|
||||
with:
|
||||
retry_wait_seconds: 60
|
||||
timeout_minutes: 45
|
||||
max_attempts: 3
|
||||
command: |
|
||||
pushd projects/rocprofiler-systems/docker
|
||||
./build-docker.sh --distro ${{ matrix.os-distro }} --versions ${{ matrix.os-version }} --rocm-versions ${{ matrix.rocm-version }} --user ${{ secrets.ROCPROF_SYS_DOCKER_LOGIN }} --push
|
||||
popd
|
||||
|
||||
Referencia en una nueva incidencia
Block a user