Skip to content

Commit

Permalink
ci: clone main from mock-configs
Browse files Browse the repository at this point in the history
  • Loading branch information
lleyton committed Jul 23, 2024
1 parent 232a217 commit 3cfc25b
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 16 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/autobuild.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,16 +51,27 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Checkout latest Mock configs
uses: actions/checkout@v4
with:
repository: terrapkg/mock-configs
path: mock-configs

- name: Set up git repository
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"

- name: Include custom build template instead of package default
run: |
cp -v mock-configs/terra.tpl /etc/mock/templates/terra.tpl
- name: Build with Andaman
run: anda build ${{ matrix.pkg.pkg }} --package rpm -c terra-${{ matrix.version }}-${{ matrix.pkg.arch }}
run: anda build ${{ matrix.pkg.pkg }} --package rpm -c mock-configs/terra-${{ matrix.version }}-${{ matrix.pkg.arch }}.cfg

- name: Build with Andaman (alternate arch)
if: |
matrix.pkg.arch == 'x86_64' && matrix.pkg.labels['multilib']
run: anda build ${{ matrix.pkg.pkg }} --package rpm -c terra-${{ matrix.version }}-i386
run: anda build ${{ matrix.pkg.pkg }} --package rpm -c mock-configs/terra-${{ matrix.version }}-i386.cfg

- name: Generating artifact name
id: art
Expand Down
18 changes: 11 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,22 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Checkout latest Mock configs
uses: actions/checkout@v4
with:
repository: terrapkg/mock-configs
path: mock-configs

- name: Set up git repository
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"

- name: Cache buildroot
id: br-cache
uses: actions/cache@v4
with:
path: /var/cache
key: ${{ runner.os }}-br-${{ matrix.version }}-${{ matrix.arch }}-${{ matrix.pkg }}
- name: Include custom build template instead of package default
run: |
cp -v mock-configs/terra.tpl /etc/mock/templates/terra.tpl
- name: Build with Andaman
run: anda build anda/${{ matrix.pkg }}pkg --package rpm -c terra-${{ matrix.version }}-${{ matrix.arch }}
run: anda build anda/${{ matrix.pkg }}pkg --package rpm -c mock-configs/terra-${{ matrix.version }}-${{ matrix.arch }}.pkg

- name: Generating artifact name
id: art
Expand Down
18 changes: 11 additions & 7 deletions .github/workflows/json-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,22 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Checkout latest Mock configs
uses: actions/checkout@v4
with:
repository: terrapkg/mock-configs
path: mock-configs

- name: Set up git repository
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"

- name: Cache buildroot
id: br-cache
uses: actions/cache@v4
with:
path: /var/cache
key: ${{ runner.os }}-br-${{ matrix.version }}-${{ matrix.pkg.arch }}-${{ matrix.pkg.pkg }}
- name: Include custom build template instead of package default
run: |
cp -v mock-configs/terra.tpl /etc/mock/templates/terra.tpl
- name: Build with Andaman
run: anda build ${{ matrix.pkg.pkg }} --package rpm -c terra-${{ matrix.version }}-${{ matrix.pkg.arch }}
run: anda build ${{ matrix.pkg.pkg }} --package rpm -c mock-configs/terra-${{ matrix.version }}-${{ matrix.pkg.arch }}.pkg

- name: Generating artifact name
id: art
Expand Down

0 comments on commit 3cfc25b

Please sign in to comment.