feat: arr theme env variables #299
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: "Pull Request: Validate" | |
on: | |
pull_request: | |
branches: | |
- main | |
concurrency: | |
group: ${{ github.head_ref }}-pr-validate | |
cancel-in-progress: true | |
jobs: | |
pr-metadata: | |
uses: onedr0p/containers/.github/workflows/pr-metadata.yaml@main | |
generate-build-matrix: | |
name: Generate matrix for building images | |
runs-on: ubuntu-latest | |
needs: ["pr-metadata"] | |
outputs: | |
matrix: ${{ steps.get-changed.outputs.changes }} | |
if: ${{ needs.pr-metadata.outputs.addedOrModifiedImages }} != '[]' | |
steps: | |
- name: Install tools | |
run: sudo apt-get install moreutils jo | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
- name: Fetch modified images | |
id: get-changed | |
shell: bash | |
run: | | |
declare -a changes_array=() | |
while read -r app | |
do | |
while read -r channel | |
do | |
change="$(jo app="$app" channel="$channel")" | |
changes_array+=($change) | |
done < <(jq --raw-output -c '.channels[] | .name' "./apps/$app/metadata.json") | |
done < <(echo '${{ needs.pr-metadata.outputs.addedOrModifiedImages }}' | jq --raw-output -c '.[]') | |
output="$(jo -a ${changes_array[*]})" | |
echo "changes=${output}" >> $GITHUB_OUTPUT | |
images-build: | |
uses: onedr0p/containers/.github/workflows/action-image-build.yaml@main | |
needs: ["generate-build-matrix"] | |
with: | |
imagesToBuild: "${{ needs.generate-build-matrix.outputs.matrix }}" | |
secrets: inherit |