mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-21 05:44:07 -07:00
Added documentation for DNS
This commit is contained in:
parent
c22d65b1e4
commit
be74f1fd4a
22 changed files with 137 additions and 29 deletions
|
@ -1,5 +1,13 @@
|
|||
#!/bin/bash
|
||||
# info: adding dns domain
|
||||
# info: add dns domain
|
||||
# arguments: user domain ip [template] [exp] [soa] [ttl]
|
||||
#
|
||||
# The function adds DNS zone with records defined in the template. If the exp
|
||||
# argument isn't stated, the expiration date value will be set to next year.
|
||||
# The soa argument is responsible for the relevant record. By default the first
|
||||
# user's NS server is used. TTL is set as common for the zone and for all of
|
||||
# its records with a default value of 14400 seconds.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,12 @@
|
|||
#!/bin/bash
|
||||
# info: adding dns domain record
|
||||
# info: add dns domain record
|
||||
# arguments: user domain record type value [id]
|
||||
#
|
||||
# The call is used for adding new DNS record. Complex records of TXT, MX and
|
||||
# SRV types can be used by a filling in the 'value' argument. The function also
|
||||
# gets an id parameter for definition of certain record identifier or for the
|
||||
# regulation of records.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
#!/bin/bash
|
||||
# info: changing dns domain exp date
|
||||
# info: change dns domain expiriation date
|
||||
# arguments: user domain exp
|
||||
#
|
||||
# The function of changing the term of expiration domain's registration. The
|
||||
# serial number will be refreshed automatically during update.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: changing dns domain ip
|
||||
# info: change dns domain ip address
|
||||
# arguments: user domain ip
|
||||
#
|
||||
# The function for changing the main ip of DNS zone.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: changing dns domain record
|
||||
# info: change dns domain record
|
||||
# arguments: user domain id record type value
|
||||
#
|
||||
# The function for changing DNS record.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
#!/bin/bash
|
||||
# info: changing dns domain soa
|
||||
# info: change dns domain soa record
|
||||
# arguments: user domain soa
|
||||
#
|
||||
# The function for changing SOA record. This type of records can not be
|
||||
# modified by v_change_dns_domain_record call.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,11 @@
|
|||
#!/bin/bash
|
||||
# info: changing dns domain template
|
||||
# info: change dns domain template
|
||||
# arguments: user domain
|
||||
#
|
||||
# The function for changing the template of records. By updating old records
|
||||
# will be removed and new records will be generated in accordance with
|
||||
# parameters of new template.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: changing dns domain ttl
|
||||
# info: change dns domain ttl
|
||||
# arguments: user domain ttl
|
||||
#
|
||||
# The function for chaning the time to live TTL parameter for all records.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
#!/bin/bash
|
||||
# info: deliting dns domain
|
||||
# info: delite dns domain
|
||||
# arguments: user domain
|
||||
#
|
||||
# The function for deleting DNS domain. By deleting it all records will also be
|
||||
# deleted.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: deleting dns record
|
||||
# info: delete dns record
|
||||
# arguments: user domain id
|
||||
#
|
||||
# The function for deleting a certain record of DNS zone.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: deleteing all user dns domains
|
||||
# info: delete dns domains
|
||||
# arguments: user
|
||||
#
|
||||
# The function for deleting all users DNS domains.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: Getting dns domain value
|
||||
# info: get dns domain value
|
||||
# arguments: user domain key
|
||||
#
|
||||
# The function for getting a certain DNS domain parameter.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: listing dns domain
|
||||
# info: list dns domain
|
||||
# arguments: user domain [format]
|
||||
#
|
||||
# The function for getting all DNS domain's parameters.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: listing dns domains
|
||||
# info: list dns domains
|
||||
# arguments: user [format]
|
||||
#
|
||||
# The function for obtaining all DNS domains of a user.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: listing dns template
|
||||
# info: list dns template
|
||||
# arguments: template [format]
|
||||
#
|
||||
# The function for obtaining the DNS template parameters.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: listing dns templates
|
||||
# info: list dns templates
|
||||
# arguments: [format]
|
||||
#
|
||||
# The function for obtaining the list of all DNS templates available.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: rebuilding dns domains
|
||||
# info: rebuild dns domains
|
||||
# arguments: user
|
||||
#
|
||||
# The function rebuilds BIND configuration files for all dns domains.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,22 +1,34 @@
|
|||
#!/bin/bash
|
||||
# Internal vesta function
|
||||
# dns system restart
|
||||
# info: restart dns service
|
||||
# arguments: none
|
||||
#
|
||||
# The function tells BIND service to reload dns zone files.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
#----------------------------------------------------------#
|
||||
|
||||
# Importing variables
|
||||
source /etc/profile.d/vesta.sh
|
||||
source $VESTA/conf/vesta.conf
|
||||
|
||||
bind() {
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Action #
|
||||
#----------------------------------------------------------#
|
||||
|
||||
if [ "$DNS_SYSTEM" = 'bind' ]; then
|
||||
/etc/init.d/named reload >/dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
#$V_FUNC/report_issue 'sys' 'cron'
|
||||
echo "$E_RESTART_FAILED $V_EVENT"
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
if [ "$DNS_SYSTEM" = 'bind' ]; then
|
||||
bind
|
||||
fi
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Vesta #
|
||||
#----------------------------------------------------------#
|
||||
|
||||
exit
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: suspening dns domain
|
||||
# info: suspend dns domain
|
||||
# arguments: user domain
|
||||
#
|
||||
# The function suspends a certain user's domain.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: suspening dns domains
|
||||
# info: suspend dns domains
|
||||
# arguments: user
|
||||
#
|
||||
# The function suspends all user's DNS domains.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: unsuspening dns domain
|
||||
# info: unsuspend dns domain
|
||||
# arguments: user domain
|
||||
#
|
||||
# The function unsuspends a certain user's domain.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
|
@ -1,5 +1,9 @@
|
|||
#!/bin/bash
|
||||
# info: unsuspening dns domains
|
||||
# info: unsuspend dns domains
|
||||
# arguments: user
|
||||
#
|
||||
# The function unsuspends all user's DNS domains.
|
||||
|
||||
|
||||
#----------------------------------------------------------#
|
||||
# Variable&Function #
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue