Allow to access environment secrets without triggering a deployment


Right now to be able to access environment secrets, you have to add the environment: Environment field in the job, and that causes GitHub actions to trigger a deployment for that environment when this job runs.

I have a use case where I want to access some of those environment secrets when running a different job, but that job does not cause the deploy itself.

Right now my workaround is to not use environment secrets, but repository secrets that have the environment as a prefix in their name. I am then dynamically exposing those inside the job.