def capabilities(): """Test capabilities functions in new distrition For openwrt: mv /etc/banner /etc/banner.disable fab -s "/bin/ash -l -c" capabilities """ print ("SYSTEM") print ("======") print("Distribution: %s" % system.distrib_id()) print("Release: %s" % system.distrib_release()) print("Codename: %s" % system.distrib_codename()) print("Desc: %s" % system.distrib_desc()) print("Arch: %s" % system.get_arch()) print("Hostname: %s" % system.get_hostname())
def capabilities(): """Test capabilities functions in new distrition For openwrt: mv /etc/banner /etc/banner.disable fab -s "/bin/ash -l -c" capabilities """ print("SYSTEM") print("======") print("Distribution: %s" % system.distrib_id()) print("Release: %s" % system.distrib_release()) print("Codename: %s" % system.distrib_codename()) print("Desc: %s" % system.distrib_desc()) print("Arch: %s" % system.get_arch()) print("Hostname: %s" % system.get_hostname())
def hostname(name): """ Require the hostname to have a specific value. """ if get_hostname() != name: set_hostname(name)
def require_isoinstall(): """ check if run in the ISO installation """ if system.get_hostname() != "archiso": abort("You seem not execute this script on iso install")