Home

Issue: 2980

Dokku Failing on Async

[issue link]

I am deploying my Nuxt App to a DigitalOcean droplet. The Build succeeds but then Dokku fails on deployment while referencing async ready function. Please see errors below;

-----> Build succeeded!
-----> Discovering process types
       Default types for  -> web
-----> Releasing intrinsic-home-website (dokku/intrinsic-home-website:latest)...
-----> Deploying intrinsic-home-website (dokku/intrinsic-home-website:latest)...
-----> Attempting to run scripts.dokku.predeploy from app.json (if defined)
-----> Running 'npm run build' in app container
remote: execution of 'npm run build' failed!
       restoring installation cache...
       > intrinsic-home-website@1.0.0 build /app
       > nuxt build
       /app/node_modules/nuxt/lib/core/module.js:14
-----> Running 'npm run build' in app container
remote: execution of 'npm run build' failed!
       restoring installation cache...
       > intrinsic-home-website@1.0.0 build /app
       > nuxt build
       /app/node_modules/nuxt/lib/core/module.js:14
         async ready() {
               ^^^^^
       SyntaxError: Unexpected identifier
           at createScript (vm.js:56:10)
           at Object.runInThisContext (vm.js:97:10)
           at Module._compile (module.js:549:28)
           at Object.Module._extensions..js (module.js:586:10)
           at Module.load (module.js:494:32)
           at tryModuleLoad (module.js:453:12)
           at Function.Module._load (module.js:445:3)
           at Module.require (module.js:504:17)
           at require (internal/module.js:20:19)
           at Object.<anonymous> (/app/node_modules/nuxt/lib/core/index.js:2:16)
       npm ERR! Linux 4.4.0-112-generic
       npm ERR! argv "/app/.heroku/node/bin/node" "/app/.heroku/node/bin/npm" "run" "build"
       npm ERR! node v6.13.1
       npm ERR! npm  v3.10.10
       npm ERR! code ELIFECYCLE
       npm ERR! intrinsic-home-website@1.0.0 build: `nuxt build`
       npm ERR! Exit status 1
       npm ERR!
       npm ERR! Failed at the intrinsic-home-website@1.0.0 build script 'nuxt build'.
       npm ERR! Make sure you have the latest version of node.js and npm installed.
       npm ERR! If you do, this is most likely a problem with the intrinsic-home-website package,
       npm ERR! not with npm itself.
       npm ERR! Tell the author that this fails on your system:
       npm ERR!     nuxt build
       npm ERR! You can get information on how to open an issue for this project with:
       npm ERR!     npm bugs intrinsic-home-website
       npm ERR! Or if that isn't available, you can get their info via:
       npm ERR!     npm owner ls intrinsic-home-website
       npm ERR! There is likely additional logging output above.
       npm ERR! Please include the following file with any support request:
       npm ERR!     /app/npm-debug.log
To intrinsichomecareservice.com:intrinsic-home-website
 ! [remote rejected] master -> master (pre-receive hook declined)

Any pointers to resolve this?

Thanks

This question is available on Nuxt.js community (#c2585)