Develop > Application Configuration > CML reference > Example CML template for /etc/hosts

Example CML template for /etc/hosts

The following is an example of a CML template that models a typical /etc/hosts file.

@#############################################
#                                            #
# /etc/hosts (multiplatform)                 #
# Version 2.0                                #
# Joe Author (joe_author@your_company.com)   #
#                                            #
#############################################@
@!namespace=/system/dns/@
@!filename-key="/files/hosts";filename-default="/etc/hosts"@
@!unordered-lines;missing-values-are-error@
@!relaxed-whitespace@
@!sequence-delimiter-is-whitespace@
@!line-comment="#"@
@~host/.ip
type = ip
printable = IP address
description = This is an IP address
@
@~host/.hostnames
type = unordered-hostname-set
printable = Hostnames
description = A set of hostnames
@
@1*host;unordered-namespace-set;;sequence-append@
@.ip@ .hostnames@
@1]@