angular.js部署到heroku失败了bootstrap-sass-official

时间:2015-09-17 15:08:42

标签: angularjs node.js heroku sass compass

我无法将angular.js应用程序部署到Heroku。我一直收到以下错误。然而,我可以在本地运行它与grunt服务或做一个咕噜的构建。我正在使用heroku buildpack https://github.com/adamgoldstein/heroku-buildpack-nodejs-grunt-compass来使罗盘工作。如果我不使用buildpack,我会收到警告'警告:无法找到compass二进制文件。'

remote: Running "wiredep:app" (wiredep) task
remote: Warning: Error: bootstrap-sass-official is not installed. Try running `bower install`. Use --force to continue.
remote: 
remote: Aborted due to warnings.
remote: 
remote: 
remote: Execution Time (2015-09-17 14:11:30 UTC)
remote: loading tasks  332ms  ▇▇▇▇▇▇▇▇▇ 18%
remote: clean:dist     130ms  ▇▇▇▇ 7%
remote: wiredep:app     1.4s  ▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇▇ 76%
remote: Total 1.9s
remote: 
remote: 
remote:  !     Push rejected, failed to compile Node.js app

我已经通过运行npm install和bower install清理并重新安装了我的node_modules和我的bower软件包。

这是我的bower.json依赖列表:

"dependencies": {
    "angular": "^1.3.0",
    "bootstrap-sass-official": "^3.2.0",
    "angular-animate": "^1.3.0",
    "angular-aria": "^1.3.0",
    "angular-cookies": "^1.3.0",
    "angular-messages": "^1.3.0",
    "angular-resource": "^1.3.0",
    "angular-route": "^1.3.0",
    "angular-sanitize": "^1.3.0",
    "angular-touch": "^1.3.0",
    "ngInfiniteScroll": "~1.2.0",
    "angular-moment": "~0.9.2",
    "userapp-angular": "~2.0.4",
    "ui-bootstrap": "~0.12.1",
    "angular-ui-router": "~0.2.13",
    "modernizr": "~2.8.3",
    "angular-bootstrap": "~0.13.0",
    "angular-xeditable": "~0.1.9",
    "ngtoast": "~1.5.2",
    "restangular": "~1.5.1",
    "jquery-bridget": "~1.1.0",
    "angular-rangeslider": "~0.0.13",
    "angular-auto-focus": "~1.0.3",
    "angular-masonry": "~0.11.0",
    "angular-masonry-directive": "*",
    "angular-rt-popup": "~1.0.6"
  },
  "devDependencies": {
    "angular-mocks": "^1.3.0"
  },

和我的package.json依赖项:

    {
  "name": "angularnews",
  "version": "0.0.0",
  "dependencies": {
    "angular": "^1.3.x",
    "bower": "~1.4.1",
    "compass": "^0.1.1",
    "express": "~4.12.3",
    "generator-angular": "~0.11.1",
    "generator-karma": "~1.0.0",
    "grunt-cli": "~0.1.13",
    "gzippo": "~0.2.0",
    "morgan": "~1.5.2",
    "yo": "~1.4.6"
  },
  "repository": {},
  "devDependencies": {
    "grunt": "^0.4.5",
    "grunt-autoprefixer": "^2.0.0",
    "grunt-concurrent": "^1.0.0",
    "grunt-contrib-clean": "^0.6.0",
    "grunt-contrib-compass": "^1.0.3",
    "grunt-contrib-concat": "^0.5.0",
    "grunt-contrib-connect": "^0.9.0",
    "grunt-contrib-copy": "^0.7.0",
    "grunt-contrib-cssmin": "^0.12.0",
    "grunt-contrib-htmlmin": "^0.4.0",
    "grunt-contrib-imagemin": "^0.9.2",
    "grunt-contrib-jshint": "^0.11.0",
    "grunt-contrib-uglify": "^0.7.0",
    "grunt-contrib-watch": "^0.6.1",
    "grunt-filerev": "^2.1.2",
    "grunt-google-cdn": "^0.4.3",
    "grunt-newer": "^1.1.0",
    "grunt-ng-annotate": "^0.9.2",
    "grunt-svgmin": "^2.0.0",
    "grunt-usemin": "^3.0.0",
    "grunt-wiredep": "^2.0.0",
    "jshint-stylish": "^1.0.0",
    "load-grunt-tasks": "^3.1.0",
    "time-grunt": "^1.0.0"
  },
  "engines": {
    "node": ">=0.10.0"
  },
  "scripts": {
    "test": "grunt test",
    "postinstall": "bower cache clean && bower install"
  }
}

有什么想法吗?

1 个答案:

答案 0 :(得分:0)

https://github.com/heroku/heroku-buildpack-nodejs buildpack添加到heroku解决了我的问题。