I have a GA workflow to deploy my React app here. It runs the checkout/install/build/test steps on a matrix of three separate NodeJS versions, then runs deployment. My concern is that, given the matrix, this will try to run deployment three times, which can cause issues. Is there a good way to filter the last step so it only runs once?
My current best guess is changing lines 30-32 to the below, but I am not certain it would work correctly.
- name: Deploy
if: matrix.node-version == '10.x' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch')
run: | ...