Tag: ruby on rails 5

在Amazon EC2空白页问题上部署Rails + React应用程序

我有轨道5 + react.js的组合应用程序。 我已经在Amazon EC2服务器上部署了它。 应用程序设置完成。 到现在为止没有错误。 问题是“变得空白页” 。 内容不在屏幕上呈现。 节点模块已经安装在服务器上。 来自我的package.json文件的代码 "scripts": { "test": "echo \"Error: no test specified\" && exit 1", "webpack": "./node_modules/.bin/webpack –watch", "heroku-postbuild": "webpack –config webpack.config.prod.js" } 告诉我发生了什么事

Rails 5 – ActionCable – 无法升级到WebSocket

我试图在我的Rails 5应用程序上实现一个webSocket。 这是我的频道: class MessagesChannel < ApplicationCable::Channel def subscribed stream_from "messages_#{params[:topic]}" end end 在我的控制器我做: ActionCable.server.broadcast "messages_#{params[:topic_id]}", message: @message.message, user: current_user.name 和我的连接类(使用设备也): module ApplicationCable class Connection < ActionCable::Connection::Base identified_by :current_user def connect self.current_user = find_verified_user logger.add_tags 'ActionCable', current_user.email end protected def find_verified_user # this checks whether a user is authenticated with devise if verified_user = env['warden'].user […]

无法检测到设置buildpack https://github.com/jasonswett/heroku-buildpack-nodejs

我为这个开发者购买了这本书。 当去Heroku我得到一个未能检测集buildpack。 我已经包含了我的package.json。 任何帮助将不胜感激。 谢谢 terminal错误消息时… $ git push heroku master Writing objects: 100% (64/64), 15.94 KiB | 0 bytes/s, done. Total 64 (delta 1), reused 0 (delta 0) remote: Compressing source files… done. remote: Building source: remote: remote: —–> Failed to detect set buildpack https://github.com/jasonswett/ heroku-buildpack-nodejs remote: More info: https://devcenter.heroku.com/articles/buildpacks#detection-failure remote: remote: ! Push […]