Build and deploy on master/PR/tagged brach?

how I can only build and deploy for master,PR and tagged branch?

thanks