0

I have an issue while deploying my nodejs app on dotCloud regarding the dependencies. This app use node-canvas (https://github.com/LearnBoost/node-canvas) to generate a thumbnail of the sheet music (related to the music sheets available on jellynote.com).

I don't have any error during the push of my application and the installation of the dependencies. Here is my package.json file:

{
  "name": "jellyscore",
  "version": "1.0.0",
  "dependencies": {
    "canvas": "",
    "mongodb": ""
  }
}

and here is the logs that dotCloud return (edited log):

node.js:134
        throw e; // process.nextTick error, or 'error' event on first tick
        ^
Error: Cannot find module '../build/default/canvas'
    at Function._resolveFilename (module.js:326:11)
    at Function._load (module.js:271:25)
    at require (module.js:355:19)
    at Object.<anonymous> (/home/dotcloud/node_modules/canvas/lib/bindings.js:7:20)
    at Module._compile (module.js:411:26)
    at Object..js (module.js:417:10)
    at Module.load (module.js:343:31)
    at Function._load (module.js:302:12)
    at require (module.js:355:19)
    at Object.<anonymous> (/home/dotcloud/node_modules/canvas/lib/canvas.js:12:14)

Thanks!

arthur
  • 950
  • 1
  • 5
  • 18
  • 1
    It looks like you are missing some of your logs, can you post the full error message? To see the full log you can 'dotcloud ssh and then go to /var/log/supervisor/ and look at the logs in there and find the one with the best information. jellyscore-stderr---supervisor-DLBeK_.log is a good place to start, but you might have better info in a different log file as well. – Ken Cochrane Oct 16 '12 at 12:40
  • I edited the logs in the main question, thanks :) – arthur Oct 16 '12 at 14:38

1 Answers1

3

Have you added CAIRO as system dependency ?

in you dotCloud yml:

systempackages:
    - libcairo2

So if you have a Node.js only app it should look like this:

www:
    type: nodejs
    systempackages:
       - libcairo2
3on
  • 6,291
  • 3
  • 26
  • 22