Closed nonholamilza closed 6 months ago
Hey @nonholamilza, glad to hear it works!
Yeah, you can set the server hostname to any name you want only that you keep it consistent through out. Just set the correct A (and optionally AAAA) records for the hostname you choose e.g. pizza.thiscoolwebsite.com
to point to the server's IP address, then use it in the DNS and mail client settings where the server hostname is required.
Also remember to set it in the file /root/private_vars/vars.yml
that is created in the server, then run the ansible-playbook
command.
Thanks for the answer, it's not clear to me on this point.
The seconds times what's the file to edit and what's the setup command?
I mean, it's not clear to me if the file to edit is:
/root/primvate_vars/vars.yml
/replatform/site.yml
/replatform/vars.yml
and the command is:
ansible-playbook site.yml
(for everytime)
or it change the seconds in ansible-playbook vars.yml
(in that cas, the replatform or root dir one?)
Thanks a lot, really great work!
Yes, you're close. The file to edit (in the server) is /root/private_vars/vars.yml
. Set the new host name there as the value for server_hostname
.
Afterwards, run ansible-playbook site.yml
. That is the command to run every time which will make sure everything is properly configured. You get it now?
Sure! Thanks, it was already clear, now it is more so.
I'll let you know :)
Hello, I used your script into a new VPS, following your clear instructions. Everything works!
But there's a way to change the Server Hostname?
myplatform.example.org
both subdomain? like 'serverhostname.example.org' and the domain? like 'pizza.thiscoolwebsite.com'Thanks for your script, it works fine :)