Skip to content

Sync package repositories #680

Sync package repositories

Sync package repositories #680

Workflow file for this run

---
name: Sync package repositories
on:
workflow_call:
inputs:
sync_ark:
description: Sync package repositories in Ark
type: boolean
required: true
sync_test:
description: Sync package repositories in Test Pulp
type: boolean
required: true
filter:
description: Space-separated list of regular expressions matching short_name of repositories to sync
type: string
required: true
workflow_dispatch:
inputs:
sync_ark:
required: false
description: Sync package repositories in Ark
default: true
type: boolean
sync_test:
required: false
description: Sync package repositories in Test Pulp
default: true
type: boolean
filter:
description: Space-separated list of regular expressions matching short_name of repositories to sync
type: string
required: false
default: ""
env:
ANSIBLE_FORCE_COLOR: True
ANSIBLE_VAULT_PASSWORD_FILE: ${{ github.workspace }}/vault-pass
jobs:
package-sync-ark:
name: Sync package repositories in Ark
runs-on: ubuntu-latest
if: inputs.sync_ark
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Release Train & dependencies
uses: ./.github/actions/setup
with:
vault-password: ${{ secrets.ANSIBLE_VAULT_PASSWORD }}
vault-password-file: ${{ env.ANSIBLE_VAULT_PASSWORD_FILE }}
- name: Sync and publish package repositories in Ark
run: |
ansible-playbook -i ansible/inventory \
ansible/dev-pulp-repo-sync.yml \
ansible/dev-pulp-repo-publication-cleanup.yml \
ansible/dev-pulp-repo-publish.yml \
-e deb_package_repo_filter="'$FILTER'" \
-e rpm_package_repo_filter="'$FILTER'"
env:
FILTER: ${{ inputs.filter }}
package-sync-test:
name: Sync package repositories in test
runs-on: [self-hosted, stackhpc-release-train]
needs: package-sync-ark
if: inputs.sync_test
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Release Train & dependencies
uses: ./.github/actions/setup
with:
vault-password: ${{ secrets.ANSIBLE_VAULT_PASSWORD }}
vault-password-file: ${{ env.ANSIBLE_VAULT_PASSWORD_FILE }}
- name: Sync and publish package repositories in test
run: |
ansible-playbook -i ansible/inventory \
ansible/test-pulp-repo-version-query.yml \
ansible/test-pulp-repo-sync.yml \
ansible/test-pulp-repo-publication-cleanup.yml \
ansible/test-pulp-repo-publish.yml \
-e deb_package_repo_filter="'$FILTER'" \
-e rpm_package_repo_filter="'$FILTER'"
env:
FILTER: ${{ inputs.filter }}