replaced underscore with dash in api syscalls

This commit is contained in:
Serghey Rodin 2012-11-09 18:26:32 +02:00
commit b6b7eacadb
283 changed files with 438 additions and 412 deletions

47
bin/v-change-sys-ip-name Executable file
View file

@ -0,0 +1,47 @@
#!/bin/bash
# info: change ip name
# options: ip name
#
# The function for changing dns domain associated with ip.
#----------------------------------------------------------#
# Variable&Function #
#----------------------------------------------------------#
# Argument defenition
ip=$1
ip_name=$2
# Includes
source $VESTA/conf/vesta.conf
source $VESTA/func/main.sh
source $VESTA/func/ip.sh
#----------------------------------------------------------#
# Verifications #
#----------------------------------------------------------#
check_args '2' "$#" 'ip ip_name'
validate_format 'ip' 'ip_name'
is_ip_valid
#----------------------------------------------------------#
# Action #
#----------------------------------------------------------#
# Changing ip name
update_ip_value '$NAME' "$ip_name"
#----------------------------------------------------------#
# Vesta #
#----------------------------------------------------------#
# Logging
log_history "changed associated dns on $ip to $domain" '' 'admin'
log_event "$OK" "$EVENT"
exit