A year later and I'm running into this issue, too! There seems to be some nuance that I'm missing about connecting to the cluster - although our authentication is set up to be a basic username and password. And we have no ports blocked to the cluster. What a headache!
I'm embarassed to say the "Gateway" issue is caused by disabling the Thrift servers in our cluster. We did this because our primary use cases are PySpark in nature and therefore do not require Thrift services. Re-enabling the Thrift server facilitates connection of PBI to the Spark cluster.