@shweta singh
The pre-ambari-start recipes are running in the same salt state as the ambari-install, so they are running parallel. Salt is trying to run highstate more times, so after the pre-ambari-start recipes are finished with the proxy and repo settings the ambari-install phase should be successfull. The ambari repository settings can be set on the UI or from the CLI as well.
Anyway in the next TP version of Cloudbreak (2.5) proxy setup for clusters will be in techpreview phase. You can try clusters behind proxy in that version.