0

我最近将基于 Meteor 的网站从 1.3 更新到了 1.8,同时包括了 Let's Encrypt SSL。当我在使用 MUP 部署后尝试添加新用户时,用于添加用户的 UI 折叠为三个频闪栏,但从未完成。当我尝试在另一个浏览器中运行该页面时,它会给我一个 502 Bad Gateway 错误。当我刷新尝试创建帐户的原始页面时,此 502 错误消失。

我使用提供的“交钥匙”帐户进行构建。在我的家用计算机上进行本地测试时效果很好。

这是所有安装包,包括删除不安全和后的默认包:

meteor-base@1.4.0             # Packages every Meteor app needs to have
mobile-experience@1.0.5       # Packages for a great mobile UX
mongo@1.6.2                   # The database Meteor supports right now
blaze-html-templates@1.0.4 # Compile .html files into Meteor Blaze views
reactive-var@1.0.11            # Reactive variable for tracker
tracker@1.2.0                 # Meteor's client-side reactive programming library

standard-minifier-css@1.5.3   # CSS minifier run for production mode
standard-minifier-js@2.4.1    # JS minifier run for production mode
es5-shim@4.8.0                # ECMAScript 5 compatibility for older browsers
ecmascript@0.12.4              # Enable ECMAScript2015+ syntax in app code
shell-server@0.4.0            # Server-side component of the `meteor shell` command

alexwine:bootstrap-4
oauth
iron:router
accounts-ui
accounts-password
accounts-facebook
accounts-google
session
underscore
facebook-config-ui
google-config-ui

而且这是运行股票账户,没有特殊代码。我已经在 J​​avaScript 文件的面向客户端的一侧设置了用户名和电子邮件的登录:

Accounts.ui.config({
  passwordSignupFields: "USERNAME_AND_EMAIL"
});

真正令人沮丧的是,当我的网站在我的本地机器上运行以根据需要进行测试、添加和更新用户时,我的网站工作正常,但由于某种原因在部署时却陷入了困境。

我迷路了,我什至不知道是什么导致它如此严重地挂起。任何帮助是极大的赞赏!

编辑:添加 package.json

{
  "name": "DMachineWordBank",
  "private": true,
  "scripts": {
    "start": "meteor run",
    "test": "meteor test --once --driver-package meteortesting:mocha",
    "test-app": "TEST_WATCH=1 meteor test --full-app --driver-package meteortesting:mocha",
    "visualize": "meteor --production --extra-packages bundle-visualizer"
  },
  "dependencies": {
    "@babel/runtime": "^7.3.4",
    "bcrypt": "^3.0.6",
    "meteor-node-stubs": "^0.4.1",
    "popper.js": "^1.15.0"
  },
  "meteor": {
    "mainModule": {
      "client": "client/main.js",
      "server": "server/main.js"
    },
    "testModule": "tests/main.js"
  }
}
4

1 回答 1

0

如果您删除 bcrpt 并忽略以下消息,它会修复生产吗?

Note: you are using a pure-JavaScript implementation of bcrypt.
While this implementation will work correctly, it is known to be
(STDERR) approximately three times slower than the native implementation.
In order to use the native implementation instead, run

    meteor npm install --save bcrypt

in the root directory of your application.
于 2019-07-19T02:48:25.923 回答