Skip to content

[Invalid] Test new branch #280

[Invalid] Test new branch

[Invalid] Test new branch #280

Workflow file for this run

name: Build and Push Docker Image
on:
workflow_dispatch:
push:
branches:
- 'main'
tags:
- 'v*'
paths:
- '.github/workflows/_docker-build.yml'
- '.github/workflows/docker.yml'
- 'docker-bake.hcl'
- 'cann/**'
- 'pytorch/**'
- 'mindspore/**'
- '!**/*.md'
pull_request:
branches:
- 'main'
paths:
- '.github/workflows/_docker-build.yml'
- '.github/workflows/docker.yml'
- 'docker-bake.hcl'
- 'cann/**'
- 'pytorch/**'
- 'mindspore/**'
- '!**/*.md'
release:
types:
- 'published'
concurrency:
group: "${{ github.workflow }}-${{ github.ref }}-${{ github.event_name == 'workflow_dispatch' }}-${{ github.event_name == 'schedule' }}"
cancel-in-progress: ${{ !contains(github.ref, 'release/')}}
env:
registries: |
[
{
"url": "docker.io",
"owner": "${{ secrets.DOCKERHUB_OWNER }}"
},
{
"url": "ghcr.io",
"owner": "${{ github.repository_owner }}"
},
{
"url": "quay.io",
"owner": "${{ secrets.QUAY_OWNER }}"
}
]
jobs:
prepare:
name: prepare
runs-on: ubuntu-latest
outputs:
cann-targets: ${{ steps.list-cann-target.outputs.targets }}
pth-targets: ${{ steps.list-pth-target.outputs.targets }}
ms-targets: ${{ steps.list-ms-target.outputs.targets }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: List cann targets
id: list-cann-target
uses: docker/bake-action/subaction/list-targets@v4
with:
target: cann
- name: List pytorch targets
id: list-pth-target
uses: docker/bake-action/subaction/list-targets@v4
with:
target: pytorch
- name: List mindspore targets
id: list-ms-target
uses: docker/bake-action/subaction/list-targets@v4
with:
target: mindspore
cann:
name: cann
permissions:
packages: write
needs:
- prepare
uses: ./.github/workflows/_docker-build.yml

Check failure on line 90 in .github/workflows/docker.yml

View workflow run for this annotation

GitHub Actions / Build and Push Docker Image

Invalid workflow file

The workflow is not valid. In .github/workflows/docker.yml (Line: 90, Col: 11): Error from called workflow cosdt/dockerfiles/.github/workflows/_docker-build.yml@b59411bdd5b2a6046b0d0324cd443e1db0211bdf (Line: 139, Col: 13): Unrecognized named-value: 'secrets'. Located at position 26 within expression: inputs.push == 'true' && secrets.DOCKERHUB_USERNAME && secrets.DOCKERHUB_TOKEN In .github/workflows/docker.yml (Line: 90, Col: 11): Error from called workflow cosdt/dockerfiles/.github/workflows/_docker-build.yml@b59411bdd5b2a6046b0d0324cd443e1db0211bdf (Line: 155, Col: 13): Unrecognized named-value: 'secrets'. Located at position 26 within expression: inputs.push == 'true' && secrets.QUAY_USERNAME && secrets.QUAY_TOKEN
with:
targets: ${{ needs.prepare.outputs.cann-targets }}
push: ${{ github.event_name != 'pull_request' }}
secrets:
DOCKERHUB_OWNER: ${{ secrets.DOCKERHUB_OWNER }}
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
QUAY_OWNER: ${{ secrets.QUAY_OWNER }}
QUAY_USERNAME: ${{ secrets.QUAY_USERNAME }}
QUAY_TOKEN: ${{ secrets.QUAY_TOKEN }}
pytorch:
name: pytorch
if: ${{ success() || failure() }}
permissions:
packages: write
needs:
- prepare
- cann
uses: ./.github/workflows/_docker-build.yml
with:
targets: ${{ needs.prepare.outputs.pth-targets }}
push: ${{ github.event_name != 'pull_request' }}
secrets:
DOCKERHUB_OWNER: ${{ secrets.DOCKERHUB_OWNER }}
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
QUAY_OWNER: ${{ secrets.QUAY_OWNER }}
QUAY_USERNAME: ${{ secrets.QUAY_USERNAME }}
QUAY_TOKEN: ${{ secrets.QUAY_TOKEN }}
mindspore:
name: mindspore
if: ${{ success() || failure() }}
permissions:
packages: write
needs:
- prepare
- cann
uses: ./.github/workflows/_docker-build.yml
with:
targets: ${{ needs.prepare.outputs.ms-targets }}
push: ${{ github.event_name != 'pull_request' }}
secrets:
DOCKERHUB_OWNER: ${{ secrets.DOCKERHUB_OWNER }}
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_TOKEN: ${{ secrets.DOCKERHUB_TOKEN }}
QUAY_OWNER: ${{ secrets.QUAY_OWNER }}
QUAY_USERNAME: ${{ secrets.QUAY_USERNAME }}
QUAY_TOKEN: ${{ secrets.QUAY_TOKEN }}