2015-12-25 73 views
2

終於我可以mupx這mup.json部署我的項目:不能從自己的域達到部署流星項目

{ 
    "servers": [ 
    { 
     "host": "servers IP", 
     "username": "root", 
     "password": "blablabla", 
     "env": {} 
    } 
    ], 
    "setupMongo": false, 
    "appName": "myApp", 
    "app": "/var/www/vhosts/deploy.myApp", 
    "env": { 
    "PORT": 800, 
    "ROOT_URL": "http://myDomain", 
    "MONGO_URL": "mongodb://login:[email protected]:1111/myApp_com" 
    }, 
    "deployCheckWaitTime": 120, 
    "enableUploadProgressBar": true 
} 

我使用"PORT": 800因爲我在服務器上的Plesk面板,並與80端口我得到的錯誤:

x Invoking deployment process: FAILED 

    -----------------------------------STDERR----------------------------------- 
    Error response from daemon: no such id: 

但我更改端口後,部署成功。

但我仍然無法弄清楚如何從我的域名豐富我的應用程序?

其實我只是覺得,我能達到我的應用程序是這樣的:http://mydomain:800/

但如何部署端口80(這是域標準),如果端口80已經忙不過來的Plesk面板?

回答

0

你需要的是一個reverse proxy

In computer networks, a reverse proxy is a type of proxy server that retrieves resources on behalf of a client from one or more servers. These resources are then returned to the client as though they originated from the proxy server itself.

,將根據一定的路由規則來聽你的80端口請求轉發到相應的應用程序的服務器。最流行的解決方案之一是nginx。

This tutorial提供了有關如何在Plex上安裝nginx的信息。並且meteorpedia有配置nginx流星的a good article

+0

我已經與apache + nginax plesk,但我現在不怎麼配置nginax,我從來沒有做過 –