Warning this answer is for sharepoint 2010 only:
After a long trial and mistake journey I figured the best way is to deploy everything through wsps and content deployment packages (using Export-SPWeb & Import-SPWeb cmdlets).
to find out more read this.
the second best way is to:
1.Backup the web application through the central administration from the source server.
2.Restore the web application through the central administration to the destination server.
3.Copy all the resources in the virtual directory (wpresources, bin, web.config...) to the destination server.
4.Deploy All solution packages (wsps) if available on the destination server.
5.Make any custom changes needed (create external databases ....) and you're ready to go :)
Good luck with both ways.