$hostname()

DESCRIPTION
    returns the system hostname
SYNOPSIS
    $hostname()
ARGUMENTS
    none
EXAMPLES
# pikt +C 'output $hostname()'
budapest
                        =output_other_mail(MAIL, 'PIKT Alert on $hostname(): Warning',
                                           =piktadmin,
                                           "$name is outdated, is $text(#fa) days old")
        rule    // do the backup
                =execwait "=cp -p $name $precdir/$base\." . $hostname()
                        // possibly page
#ifdef page
                        if    #hr > %hr         // no repeats within the hour
#  if misscritsys
                           && #hr % 1 == 0      // page hourly
                                =page($hostname() $mount is full, =pagesysadmins,
                                      =allhours(#now()))
#    if db
                                =page($hostname() $mount is full, =pagedbadmins, =allhours(#now()))
#    endif
#  else
                           && #hr % 2 == 0      // page every two hours
                                =page($hostname() $mount is full, =pagesysadmins,
                                      ! =offhours(#now()))
#  endif
                        endif
#endifdef
SEE ALSO
    String Functions
    Numerical Functions
 
Home | FAQ | News | Intro | Samples | Tutorial | Reference | Software
Developer's Notes | Licensing | Authors | Pikt-Users | Pikt-Workers | Related Projects | Site Index | Privacy Policy | Contact Us
Page best viewed at 1024x768 or greater.   Page last updated 2019-01-12.   This site is PIKT® powered.
Copyright © 1998-2019 Robert Osterlund. All rights reserved.
Home FAQ News Intro Samples Tutorial Reference Software
PIKT Logo
PIKT Page Title
Learn about the
PIKT alarms.cfg
config file