title: How can I run my hybrid mobile app in debug/development mode on an iPhone?
body: <p><strong>TL;DR:</strong> I can run our app in development mode through VS2015 with remote debugging on the iPhone 5c that I have, but I cannot do the same on the iPhone 4s.</p>
  
  <hr>
  
  <p>I'm having some difficulty getting a Cordova powered hybrid app to deploy on one particular device in my development environment... However I'm unsure if this is something I'm doing wrong or if there's some compatibility issue here. Posting a question here in the hopes that someone can help me work out what's going on.</p>
  
  <p>Just for some background: The app in question was created using Intel XDK, then ported across to Visual Studio 2015 when Intel recently removed some of XDK's "Debug" functionality. A few things needed to be adapted, but the project does still include some of Intel's JS code as it was in the original project.</p>
  
  <p>My environment includes:</p>
  
  <ul>
  <li>Windows 10 Pro (primary desktop)</li>
  <li>Apple Mac Mini with OSX "El Capitan" 10.11.6 (on the network as a build server)</li>
  <li>iPhone 5c with iOS 8.3</li>
  <li>iPhone 4s with iOS 9.0.2</li>
  </ul>
  
  <p>While configuring this environment, I followed the <a href="https://taco.visualstudio.com/en-us/docs/ios-guide/" rel="noreferrer">instructions here</a>. The <code>remotebuild</code> agent is configured to use <code>http</code> only to keep it simple, since this is all contained within a corporate network anyway.</p>
  
  <p>After this I could run our app on the iPhone 5c without any problems, but trying to run it on the iPhone 4s gives an error in VS2015 stating:</p>
  
  <p><code>
  Failed to deploy iOS remote for &lt;project_path&gt;\bld\ios\Debug\buildInfo.json to http://10.66.7.23:3000/cordova:
  Error from http get [object Object]: Error: socket hang up
  </code></p>
  
  <p>Note: There are no errors in the <code>remotebuild</code> console output on the Mac and VS <em>builds</em> the project correctly, but then fails to <em>deploy</em> it.</p>
  
  <p>I've also tried multiple Provisioning Profiles on both devices, installed using iTunes, Xcode or Apple Configurator 2; but thanks to the provisioning profiles not showing up on devices with iOS 8 or newer, I can't even verify that they're installed at all.</p>
  
  <p>Both of these devices can install and run the previous version of this app (available in app stores), but I need to be able to inspect the DOM in real-time, because even though they have the same screen size, the responsive break points are behaving differently.</p>
  
  <p>So, before I pull out what little hair I do have left, please could somebody help me work out what the hell is going on here?? I've been fighting with this for over a week now and I feel like I'm going round in circles.</p>