chore(deps): bump actions/checkout from 4.1.7 to 4.2.2 #35
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: create-repo-yum | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} | |
cancel-in-progress: true | |
on: | |
workflow_dispatch: | |
pull_request: | |
paths: | |
- ".github/workflows/create-repo-yum.yml" | |
jobs: | |
get-environment: | |
uses: ./.github/workflows/get-environment.yml | |
with: | |
version_file: centreon/www/install/insertBaseConf.sql | |
create-repo-file-and-deliver: | |
needs: [get-environment] | |
if: ${{ needs.get-environment.outputs.skip_workflow == 'false' }} | |
runs-on: ubuntu-24.04 | |
strategy: | |
matrix: | |
distrib: [el8, el9] | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: Install jfrog cli | |
uses: jfrog/setup-jfrog-cli@f0a84f35b0e0bd21838c5fb3e6788072d6540d13 # v4.5.5 | |
env: | |
JF_URL: https://centreon.jfrog.io | |
JF_ACCESS_TOKEN: ${{ secrets.ARTIFACTORY_ACCESS_TOKEN }} | |
- name: Create repository structure | |
run: | | |
for STABILITY in "unstable" "testing" "stable"; do | |
for ARCH in "noarch" "x86_64"; do | |
curl -H "Authorization: Bearer ${{ secrets.ARTIFACTORY_ACCESS_TOKEN }}" -X PUT "https://centreon.jfrog.io/artifactory/rpm-standard/${{ needs.get-environment.outputs.major_version }}/${{ matrix.distrib }}/$STABILITY/$ARCH/" | |
curl -H "Authorization: Bearer ${{ secrets.ARTIFACTORY_ACCESS_TOKEN }}" -X POST "https://centreon.jfrog.io/artifactory/api/yum/rpm-standard?path=/${{ needs.get-environment.outputs.major_version }}/${{ matrix.distrib }}/$STABILITY/$ARCH&async=1" | |
curl -H "Authorization: Bearer ${{ secrets.ARTIFACTORY_ACCESS_TOKEN }}" -X PUT "https://centreon.jfrog.io/artifactory/rpm-plugins/${{ matrix.distrib }}/$STABILITY/$ARCH/" | |
curl -H "Authorization: Bearer ${{ secrets.ARTIFACTORY_ACCESS_TOKEN }}" -X POST "https://centreon.jfrog.io/artifactory/api/yum/rpm-plugins?path=/${{ matrix.distrib }}/$STABILITY/$ARCH&async=1" | |
done | |
done | |
shell: bash | |
- name: Create repo file | |
run: | | |
sed \ | |
-e "s#@MAJOR_VERSION@#${{ needs.get-environment.outputs.major_version }}#g" \ | |
-e "s#@DISTRIB@#${{ matrix.distrib }}#g" \ | |
./.github/scripts/repo/centreon.repo.template > ./centreon-${{ needs.get-environment.outputs.major_version }}.repo | |
shell: bash | |
- name: Upload repo file in jfrog | |
run: | | |
jf rt upload "centreon-${{ needs.get-environment.outputs.major_version }}.repo" "rpm-standard/${{ needs.get-environment.outputs.major_version }}/${{ matrix.distrib }}/" | |
shell: bash | |
set-skip-label: | |
needs: [get-environment, create-repo-file-and-deliver] | |
if: | | |
needs.get-environment.outputs.skip_workflow == 'false' && | |
! cancelled() && | |
! contains(needs.*.result, 'failure') && | |
! contains(needs.*.result, 'cancelled') | |
uses: ./.github/workflows/set-pull-request-skip-label.yml |