Looking for an old polish movie about a priest and a man wanting to commit a crime

Please help me find this movie. I can’t find it on Netflix anymore. I think it to be polish. It’s about this man confessing to a priest that he wants to murder someone. Of course the priest advises against it and tells the man he’ll do it for him instead. The film has homosexual undertones, i think. There’s this haunting and disquieting sequence where the priest follows the man into the mountain. Must have been released in the 70s or 80s could be early 90s too. Thank you in advance.