By max gonzalez
Someone knows how to do to address two different domains to a single ip. I was trying on the panel, but I got confused a bit and I did not succeed, I only managed to access a single domain.
What I want is that “mydomain.cl” and “maydomain.com” come to my same application.
Well I hope some clue. Thank you
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!
Thanks, you’re right, I’ll do the tutorial steps, as you suggest. And I’ll let you know the result.
<<<<Domains and ip number replace them with “xxxx” and “999” for obvious reasons of privacy and security in this publication>>>
Hi, I really need help with this. I did according to the steps of the tutorial but with some changes, because my site is already working well on the web and I do not want it to fall.
I explain: I have a domain www.xxxxxx.cl which is working super well, all this works for me in / home / max / myproject
/ etc / nginx / sites-available / myproject
Contains: Server { Listen 80; Server_name 99.999.999.99 xxx.cl www.xxx.cl; 500M client_max_body_size; Location = /favicon.ico {access_log off; Log_not_found off; } Location / static / { Root / home / max / myproject; }
Location / { Include proxy_params; Proxy_pass http: // unix: /home/max/myproject/myproject.sock; } }
And my other file
/ etc / nginx / sites-available / myproject2
server { listen 80; server_name 99.999.999.99 xxx.com www.xxx.com; client_max_body_size 500M; location = /favicon.ico { access_log off; log_not_found off; } location /static/ { root /home/max/myproject; }
location / {
include proxy_params;
proxy_pass http://unix:/home/max/myproject/myproject.sock;
}
}
****************** My settings.py file ****************
ALLOWED_HOSTS = [‘xxx.cl’, ‘www.xxx.cl’,’ xxx.com’, ‘www.xxx.com’ , ‘ip number’]
I enter with my domain.cl and everything works perfect
but When I enter with my domain.com, Then the browser sends me the following message “This site can’t be reached”
********************/etc/systemd/system/gunicorn.service ***************************** [Unit] Description=gunicorn daemon After=network.target
[Service] User=max Group=max WorkingDirectory=/home/max/myproject/myproject ExecStart=/home/max/myproject/myprojectenv/bin/gunicorn --workers 3 -u max -g max --bind unix:/$
[Install] WantedBy=multi-user.target
Help me, what can be wrong? Do not delay in answering, if positive or negative.
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.