By Cak Nurahman
Masse
Hi guys, is possible to make my webserver accessible using 1 domain but, also can accessible also using IP address (example 114.232.232.13), how I accomplished that
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 @caknoris696:
It is possible to make your website accessible using your domain and IP. You just need to declare both your domain and IP in the server block of your Nginx configuration file as below:
server {
server_name your_domain 114.232.232.13;
}
You can read the following tutorial, especially Step 5 – Setting Up Server Blocks, for more details:
https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-ubuntu-20-04
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.