node-canvas包地址: https://github.com/Automattic/node-canvas/tree/v1.x
使用安裝命令:
$ npm install canvas
出現錯誤信息:
root@ebs-36527:/var/www/webapp_test# npm install canvas --save
npm WARN checkPermissions Missing write access to /var/www/webapp_test/node_modules/canvas
webapp@1.0.0 /var/www/webapp_test
└── canvas@1.6.6
npm WARN webapp@1.0.0 No description
npm WARN webapp@1.0.0 No repository field.
npm ERR! Linux 4.4.0-89-generic
npm ERR! argv "/home/zhangsan/Programs/node-v6.11.2-linux-x64/bin/node" "/usr/local/bin/npm" "install" "canvas" "--save"
npm ERR! node v6.11.2
npm ERR! npm v3.10.10
npm ERR! path /var/www/webapp_test/node_modules/canvas
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall access
npm ERR! enoent ENOENT: no such file or directory, access '/var/www/webapp_test/node_modules/canvas'
npm ERR! enoent ENOENT: no such file or directory, access '/var/www/webapp_test/node_modules/canvas'
npm ERR! enoent This is most likely not a problem with npm itself
npm ERR! enoent and is related to npm not being able to find a file.
npm ERR! enoent
npm ERR! Please include the following file with any support request:
npm ERR! /var/www/webapp_test/npm-debug.log
不知道是不是5天前剛好從canvas@1.6.5版本更新到canvas@1.6.6版本的原因。請大神幫忙支個招!感謝~
環境:Ubuntu 16.04.3 LTS;node v6.11.2