By hugohil
Hi,
I have a Ubuntu 14.04 droplet, running a nodejs and a nginx server. The nodejs server distribute a website on port 80, and the nginx serves a WordPress on 1337. I easily binded my domain name to the nodejs server, but am struggling to do the same for my wordpress installation … I can’t figure out how to bind my domain to a specific port (which apparently is impossible), and I can’t think of another way of binding two domains on two servers hosted on the same machine.
Help ? :)
Thank you in advance !
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi,
I’m in the same situation, but I don’t want to use blog.yourdomain.com for the blog. I would like to use yourdomain.com/blog
is it possible? (I have the nodejs app in yourdomain.com)
I think what you want to do is have your Wordpress served from nginx on port 80 and set up your node to listen on 1337. Then set up forwarding as per this tutorial.
server {
listen 80;
server_name your-domain-name.conf.com;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $http_host;
proxy_pass http://127.0.0.1:2368;
}
}
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.