TDex
By:
TDex

Ajenti-nginx subdomain problem.

August 21, 2015 1.2k views
Nginx DigitalOcean Ubuntu

Hi all.
I have a big problem.
So, i want to host my website on digitalocean servers.I created a droplet and intall Ajenti control panel.Everything is okay, i created panel.ballaroland.me subdomain, it's okay.But i want to create one other subdomain and i can't.Added the subdomain name on the DNS menu on digitalocean, and added the subdomain option in the panel but nothing, just displayed same file with the first, ballaroland.me domain.
I read something nginx block, i didn't create this blocks because i don't know how to do.
Any idea?
Zone File:
$ORIGIN ballaroland.me.
$TTL 1800
ballaroland.me. IN SOA ns1.digitalocean.com. hostmaster.ballaroland.me. 1440136052 10800 3600 604800 1800
ballaroland.me. 1800 IN NS ns1.digitalocean.com.
ballaroland.me. 1800 IN NS ns2.digitalocean.com.
ballaroland.me. 1800 IN NS ns3.digitalocean.com.
panel.ballaroland.me. 1800 IN A 128.199.41.81
ballaroland.me. 1800 IN A 128.199.41.81
www.ballaroland.me. 1800 IN CNAME ballaroland.me.
ballaroland.me. 1800 IN MX 1 aspmx.l.google.com.
ballaroland.me. 1800 IN MX 5 alt1.aspmx.l.google.com.
ballaroland.me. 1800 IN MX 5 alt2.aspmx.l.google.com.
ballaroland.me. 1800 IN MX 10 alt3.aspmx.l.google.com.
ballaroland.me. 1800 IN MX 10 alt4.aspmx.l.google.com.
test.ballaroland.me. 1800 IN A 128.199.41.81

2 Answers

In your nginx you need to create a virtual server block or file wich will handle the domain you would like to use to the proper directory. This can be done manually, but you can just create a new site inside Ajenti, and assign the domain name you want to use.

Okay, and where can i create block files? Because the public iles for the nginx is /srv/domain.

Have another answer? Share your knowledge.