Search code examples
ibm-cloudloopbackapiconnect

Unable to publish Loopback application to IBM Cloud using API designer


@ibm -

I'm getting following error while trying to publish loopback application on IBM Cloud using API Designer portal. Please help me understand why is it looking into Temp folder to publish the application and how I can bypass that. I keep getting resource busy or locked issue with apiconnect toolkit.

Here's the node, npm and apiconnect toolkit version I'm using currently. Please let me know if you need any additional details.

node - v8.9.4 npm - v5.6.0 apiconnect - v5.0.8.2 (apiconnect: v2.7.111)

Error publishing runtime: Command failed: npm prune --production npm ERR! path C:\Users\SUNNY~1.GOE\AppData\Local\Temp\0.6717806509437265-1517290270545\project\node_modules\cryptiles\node_modules\boom\package.json.1443453620 npm ERR! code EBUSY npm ERR! errno -4082 npm ERR! syscall rename npm ERR! EBUSY: resource busy or locked, rename 'C:\Users\SUNNY~1.GOE\AppData\Local\Temp\0.6717806509437265-1517290270545\project\node_modules\cryptiles\node_modules\boom\package.json.1443453620' -> 'C:\Users\SUNNY~1.GOE\AppData\Local\Temp\0.6717806509437265-1517290270545\project\node_modules\cryptiles\node_modules\boom\package.json' npm ERR! A complete log of this run can be found in: npm ERR! C:\Sunny\npm-cache_logs\2018-01-30T05_31_21_546Z-debug.log Error ID: a055ee2d-8232-459b-bf62-f4340837a61b


Solution

  • As a simple step, first run this command from cli

    apic stop all

    and try the publishing loopbaclk application to IBM Bluemix.

    In case, this does not resolve the issue, then the problem may be due to permission issues during the installation of APIC toolkit. Uninstall the toolkit do a fresh install of toolkit using '--unsafe-perm' option with the install command to overrides the permisson issues Here is the example sudo npm install --unsafe-perm -g apiconnect

    Try the publish with the new instance of API Connect and see if it resolves the issue.