Github Action Not Triggered on Pull Request

My github action is not triggering on pull requests from my forked repository into the upstream. Looking to see if anyone else has experienced this and has any suggestions. Here is my setup:

I have an orginizational project (upstream) with two branches: “master” and “next”.

I have a personal fork (origin) of the organizational project.

I then do the following:

  • make local change

  • push local change to my origin

  • create pull request in which the change will be pulled into the “next” branch on the upstream

Given my github workflow, I would expect an action to trigger but it does not.

If I merge the PR, I then see an action trigger. Any ideas why its not triggered on the PR?

Here is my github action:

name: Node.js CI

        branches: [master, next]
        branches: [master, next]

        runs-on: ubuntu-latest

                node-version: [12.x]

            - uses: actions/checkout@v2
            - name: Use Node.js ${{ matrix.node-version }}
              uses: actions/setup-node@v1
                  node-version: ${{ matrix.node-version }}
            - run: npm ci
            - run: ... other npm scripts related to my project (lint, test, etc)...
                  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
                  NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }}
                  CI: true

Hi @bdsanfelippo ,

Is your upstream repo a private one? There is an limitation for forked repo. Workflows do not run on private base repositories when you open a pull request from a forked repository. 

There is another ticket which asked for supporting pull_request events from a fork to a private base repository: You could add your comment there. 

The upstream is an internal repo to a private organization. I will look at these links - thanks.