Skip to content

Commit

Permalink
Switch to python-tools-scripts
Browse files Browse the repository at this point in the history
Signed-off-by: Pedro Algarvio <palgarvio@vmware.com>
  • Loading branch information
s0undt3ch committed Nov 24, 2023
1 parent d536219 commit fc89bfe
Show file tree
Hide file tree
Showing 34 changed files with 564 additions and 120 deletions.
20 changes: 16 additions & 4 deletions .github/workflows/.container.template.j2
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests

- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt

- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/almalinux-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/amazonlinux-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/archlinux-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/busybox-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/centos-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/centos-stream-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
20 changes: 16 additions & 4 deletions .github/workflows/consul-containers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ jobs:
if: ${{ github.repository == 'saltstack/salt-ci-containers' && contains(fromJSON('["push", "schedule", "workflow_dispatch"]'), github.event_name) }}
run: |
mkdir -p /tmp/digests
touch /tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ":" -f 2)
touch "/tmp/digests/$(echo ${{ steps.build.outputs.digest }} | cut -d ':' -f 2)"
ls -lah /tmp/digests
- name: Upload digest
Expand Down Expand Up @@ -184,12 +184,25 @@ jobs:
statuses: read

steps:

- name: "Fetching Repository Contents"
uses: actions/checkout@v4

- name: Download digests
uses: actions/download-artifact@v3
with:
name: digests-${{ needs.matrix-generator.outputs.name }}-${{ matrix.tag }}
path: /tmp/digests

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11'

- name: Install Requirements
run: |
python -m pip install -r requirements.txt
- name: Show digests
run: |
tree -a /tmp/digests
Expand Down Expand Up @@ -218,9 +231,8 @@ jobs:

- name: Create manifest list and push
working-directory: /tmp/digests
run: | # shellcheck disable=SC2046
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf 'ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }}@sha256:%s ' *)
run:
tools ci create-manifest-list-and-push ghcr.io/${{ github.repository }}/${{ needs.matrix-generator.outputs.name }} /tmp/digests

- name: Inspect image
run: |
Expand Down
Loading

0 comments on commit fc89bfe

Please sign in to comment.