Skip to content

moda-ci.yaml triggers an error in forks for anyone who doesn't have access to github/docs-internal #35731

@jsoref

Description

@jsoref

This guard

if: ${{ github.repository == 'github/docs-internal' }}

did not prevent:
Invalid workflow file: .github/workflows/moda-ci.yaml#L86

error parsing called workflow
".github/workflows/moda-ci.yaml"
-> "github/internal-actions/.github/workflows/docker_security.yml@main"
: workflow was not found. See https://docs.github.com/actions/learn-github-actions/reusing-workflows#access-to-reusable-workflows for more information.

I think it might be possible to avoid this structure by using a combination of a workflow_call with a jobs: / if: condition that guards against the user from tripping on the problem e.g. ${{ github.repository == 'github/docs-internal' }} and then have the on: workflow_call on the internal side be responsible for using the reusable workflow.

Originally posted by @jsoref in #34562 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    contentThis issue or pull request belongs to the Docs Content teamfix-internallyTriggers a workflow to copy the issue internally and close the current issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions