Reputation: 1529
I deployed my app using mup
Code
{
"servers": [
{
"host": "128.xxx.xxx.16",
"username": "root",
"pem": "~/.ssh/id_rsa"
}
],
"setupMongo": true,
"setupNode": true,
"nodeVersion": "0.10.36",
"setupPhantom": true,
"appName": "MyApp",
"app": "/home/user/work/myapp/rewrite/cf/",
"env": {
"ROOT_URL": "http://myapp.com",
"UPSTART_UID": "root",
},
"deployCheckWaitTime": 15
}
which is working fine, but now I want to install nginx in my server and installed it using apt-get
my nginx config
server {
server_name www.myapp.com;
return 301 $scheme://myapp.com$request_uri;
}
server {
listen 80;
server_name myapp.com;
location / {
proxy_pass http://127.0.0.1:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header X-Forwarded-For $remote_addr;
}
}
but this is not working when I go to my app with www
and non-www
both are taking to two different sessions,
I tried to stop meteor app using stop myapp
and go to my website I'm getting the following error page
which is I think not related to nginx
(source: meteor.com)
when I go to my server and type nginx status, it is running,
(source: meteor.com)
What is wrong with my nginx?Any help appreciated
Upvotes: 0
Views: 653
Reputation: 43
Maybe you should try dumping mup altogether. For example, I couldnt get mup to work at all on ubuntu 14.
If you're looking to get meteor running you could try this tutorial. I had to completely uninstall mongodb and mup before getting it to run on nginx.
Upvotes: 0
Reputation: 11
your mup.json file should look something like this, i guess
"env": {
"PORT":3000,
"ROOT_URL": "http://myapp.com",
"UPSTART_UID": "root",
},
Upvotes: 1