Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(cicd): make sure all image name and tags are in lower case #106

Merged
merged 1 commit into from
Nov 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 7 additions & 11 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ jobs:
- name: Make build info
id: make-build-info
run: |
echo "language=$(echo ${{ matrix.target }} | cut -d '/' -f 1 | tr '[:upper:]' '[:lower:]')" >> ${GITHUB_OUTPUT}
echo "project=$(echo ${{ matrix.target }} | cut -d '/' -f 2 )" >> ${GITHUB_OUTPUT}
echo "language=$(echo ${{ matrix.target }} | cut -d'/' -f1 | tr '[:upper:]' '[:lower:]')" >> ${GITHUB_OUTPUT}
echo "project=$(echo ${{ matrix.target }} | cut -d'/' -f2 | tr '[:upper:]' '[:lower:]')" >> ${GITHUB_OUTPUT}

- uses: docker/setup-buildx-action@v3
- uses: docker/login-action@v3
Expand Down Expand Up @@ -116,15 +116,11 @@ jobs:

steps:
- uses: actions/checkout@v3
- name: Read metadata
id: read-metadata
- name: Make build info
id: make-build-info
run: |
content=$(cat ${{ matrix.target }}/metadata.json)
content="${content//$'\n'/''}"
echo "language=$(echo $content | jq -r .language)" >> ${GITHUB_OUTPUT}
echo "id=$(echo $content | jq -r .id)" >> ${GITHUB_OUTPUT}
- run: |
echo "${{steps.read-metadata.outputs.metadata}}"
echo "language=$(echo ${{ matrix.target }} | cut -d'/' -f1 | tr '[:upper:]' '[:lower:]')" >> ${GITHUB_OUTPUT}
echo "benchmark=$(echo ${{ matrix.target }} | cut -d'/' -f2 | tr '[:upper:]' '[:lower:]')" >> ${GITHUB_OUTPUT}
- uses: docker/setup-buildx-action@v3
- uses: docker/login-action@v3
with:
Expand All @@ -137,6 +133,6 @@ jobs:
file: ${{ matrix.target }}/Dockerfile
platforms: linux/amd64
push: true
tags: ${{ env.REGISTRY }}/kupl/starlab-benchmarks/${{ steps.read-metadata.outputs.language }}:${{ steps.read-metadata.outputs.id }}
tags: ${{ env.REGISTRY }}/kupl/starlab-benchmarks/${{ steps.make-build-info.outputs.language }}:${{ steps.make-build-info.outputs.benchmark }}
labels: |
org.opencontainers.image.source="https://github.com/kupl/starlab-benchmarks"