我正在尝试使用Mup部署Meteor应用程序,并且一直给我这个错误:
[xxx.xxx.xxx.xxx] x Start Mongo: FAILED
------------------------------------STDERR------------------------------------
Error response from daemon: Container a1617b2aaaa3fd4aeb8e1241ec90ae32b4a88b0df9c95e5d73de608b68788ef0 is not running
docker: Error response from daemon: driver failed programming external connectivity on endpoint mongodb (2f5db292f7022a39dfe3ff5fdf5ed7de38ddc7bb6f787625cd0fb45a5fa10cd6): Error starting userland proxy: listen tcp 127.0.0.1:27017: bind: address already in use.
------------------------------------STDOUT------------------------------------
3.2.15: Pulling from library/mongo
Digest: sha256:ef3277c7221e8512a1657ad90dfa2ad13ae2e35aacce6cd7defabbbdcf67ca76
Status: Image is up to date for mongo:3.2.15
mongodb
mongodb
Running mongo:3.2.15
97a28fe9d2dca6130ffe6622e662a230ecea34214920673c574a4d3e57fafb3c
------------------------------------------------------------------------------
我已经检查了,可以通过ssh连接到服务器。我使用的是Digital Ocean的一键式液滴之一,因为它已经安装了Mongodb。服务器上的Mongodb版本是3.4,在我的应用程序中,我使用的是3.2.15,我不知道是否应该降级或升级其中之一,或者是否存在问题。
我的mup.js文件如下所示:
module.exports = { servers: {
one: {
host: 'xxx.xxx.xxx.xxx',
username: 'root',
pem: '~/.ssh/id_rsa'
// or neither for authenticate from ssh-agent
}
},
meteor: {
name: 'myApp',
path: '../myApp/',
servers: {
one: {},
},
buildOptions: {
serverOnly: true,
},
env: {
// If you are using ssl, it needs to start with https://
ROOT_URL: 'http://app.com',
"PORT": 80,
MONGO_URL: 'mongodb://localhost/local',
//MONGO_OPLOG_URL: 'mongodb://mongodb/local',
},
deployCheckWaitTime: 60,
docker: {
// change to 'abernix/meteord:base' if your app is using Meteor 1.4 - 1.5
image: 'abernix/meteord:base',
},
// Show progress bar while uploading bundle to server
// You might need to disable it on CI servers
enableUploadProgressBar: true
},
mongo: {
version: '3.2.15',
servers: {
one: {}
}
},
};
我为此感到疯狂,有人可以帮我吗?
最佳答案
尝试使用Ubuntu而不是mongo在Digital Ocean上创建一键式液滴,因为mup已经为您设置了mongo。我相信Meteor UP假定它正在从新设置进行部署。