phpworkeriron.io

Error pushing code to IRON.io using PHP


I'm trying to push a zip file to iron.io using PHP with cURL but I always get this error. -My teammates are able to do it, and I do the same, but that exception is generated. Have someone had the same error or problem? any ideas ? I'm kind of desperate thanks

API POST: 'https://worker-aws-us-east-1.iron.io:443/2/projects/560c4ef63dc302XXXXXXX/codes'
<br />
<b>Fatal error</b>:  Uncaught exception 'Http_Exception' with message 'http error: 400 | {&quot;msg&quot;:&quot;Code package zip file required if no image specified or using iron/images.&quot;}' in /Applications/MAMP/htdocs/www/application/libraries/ironmq/IronCore.class.php:352
Stack trace:
   #0 /Applications/MAMP/htdocs/www/application/libraries/ironmq/IronCore.class.php(343): IronCore-&gt;reportHttpError(400, '{&quot;msg&quot;:&quot;Code pa...')
   #1 /Applications/MAMP/htdocs/www/application/libraries/ironmq/IronCore.class.php(305): IronCore-&gt;callWithRetries()
   #2 /Applications/MAMP/htdocs/www/application/libraries/ironworker/IronWorker.class.php(303): IronCore-&gt;apiCall('POST', 'projects/560c4e...', Array, Array)
   #3 /Applications/MAMP/htdocs/www/application/libraries/ironworker/CIWorker.php(61): IronWorker-&gt;postCode('ironio.php', '/Applications/M...', 'lumiary-stage')
   #4 /Applications/MAMP/htdocs/www/application/controllers/admin/tools.php(52): CIWorker-&gt;package('lumiary-stage')
   #5 [internal function]: Tools-&gt;package('lumiary-stage')
   #6 /Applications/MAMP/htdocs/www/sy in <b>/Applications/MAMP/htdocs/www/application/libraries/ironmq/IronCore.class.php</b> on line <b>352</b><br />

Solution

  • The final solution was to change my PHP Version. I moved from 5.6 to 5.4 and that did the difference and everything worked as expected.