• Halloween is coming! To celebrate the occasion, we dusted off a couple of old skins, and even created a brand new one (Pixel).
    To get into the festive spirit, install the Skins extension.
  • The new Python extension is now available. It allows customers to deploy and manage WSGI-based Python applications on their websites directly from Plesk.
  • The Plesk Mobile apps for iOS and Android and the Plesk Mobile Center extension have been deprecated, and are no longer available for new installations. In Plesk Obsidian 18.0.84, the Plesk Mobile Center extension will be removed from servers during the upgrade, and the Plesk Mobile apps will lose their server management features.
  • The Social Login extension has been deprecated and will be removed in Plesk Obsidian 18.0.84. After that, it will no longer be possible to log in to Plesk with a Google, Facebook, GitHub account, or with a passkey. Plesk usernames and passwords, as well as logging in with a WebPros Account, are not affected.

DNS Records CLI

D

davividal

Guest
Hi all.

I've 2 doubts:

1 - is there any way to add DNS records through CLI? I've looked at /usr/local/psa/admin/bin but can't find anything helpful;

2 - I need (in fact, my boss wants) that every sub-domain has the 'www' prefix. Is there an "easy" ('lazyful') way to get it?

thanks
 
You can use DNS cli from following location /usr/local/psa/bin/dns or /usr/local/psa/bin/dns.sha

dns <command> [<domain_name>|<domain_alias>] [ <option_1> [<param>] [<option_2> [<param>]] … [<option_N> [<param>]] ]

./dns --set example.com -list "MX,mail3,mail.example.com,15;NS,ns2,ns.example.com"


--add or -a Adds a resource record to a domain's DNS zone.
--set or -s Adds specified resource records to and removes all pre-existing resource records from a domain's DNS zone. Requires the -list option.
--del or -d Deletes a resource record from a domain's DNS zone.
--del-all or -da Deletes all resource records from a domain's DNS zone.
--reset or -res Restores the default resource records for a domain's zone based on the Plesk server DNS zone template.
--on Enables DNS service on a domain or domain alias.
--off Disables DNS service on a domain or domain alias.
--set-master Sets the Plesk name server as the master server for domain's or domain alias' DNS zone.
--set-slave Sets the Plesk name server as the slave server for domain's or domain alias' DNS zone.
--help or -h Displays help on the use of the utility.
 
How to setup master's IP using CLI

Hi !,

Do you know how to setup IP address of master DNS after setting plesk as slave ?
I mean, using CLI, not GUI.
I dig forums but none ... and can't realize how to do this reading docs.

Thank you !
Jorge.
 
Back
Top