Add workflow to validate versions.json and test deprecated tags #1
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
on: | |
workflow_dispatch: | |
pull_request: | |
paths: | |
- versions.json | |
- .github/workflows/test-deprecated-tags.yml | |
jobs: | |
get_deprecated_tags: | |
name: Test Depreactions | |
runs-on: ubuntu-latest | |
outputs: | |
deprecatedFinalTags: ${{ steps.tags.outputs.finalTags }} | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: parse versions.json | |
id: tags | |
run: | | |
deprecatedFinalTags=$(jq -c '[.deprecations | to_entries | .[].value.finalTag]' versions.json) | |
echo "finalTags=$deprecatedFinalTags" >> $GITHUB_OUTPUT | |
echo "finalTags=$deprecatedFinalTags" | |
build: | |
runs-on: ubuntu-latest | |
needs: get_deprecated_tags | |
strategy: | |
matrix: | |
deprecatedTag: ${{ fromJSON(needs.get_deprecated_tags.outputs.deprecatedFinalTags) }} | |
steps: | |
- name: Log Inputs | |
run: | | |
echo "Deprecated Tag: ${{ matrix.deprecatedTag }}" | |
- name: Attempt Docker Pull | |
run: | | |
docker pull octopusdeploy/kubernetes-agent-tools-base:${{matrix.deprecatedTag}} |