fix secure deployment for pull requests

Fix secure deployment for pull requests