コード例 #1
0
ファイル: fabfile.py プロジェクト: AndBicScadMedia/fabrecipes
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())
コード例 #2
0
ファイル: fabfile.py プロジェクト: AndBicScadMedia/fabrecipes
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())
コード例 #3
0
ファイル: system.py プロジェクト: ianjw11/fabtools
def hostname(name):
    """
    Require the hostname to have a specific value.
    """
    if get_hostname() != name:
        set_hostname(name)
コード例 #4
0
def hostname(name):
    """
    Require the hostname to have a specific value.
    """
    if get_hostname() != name:
        set_hostname(name)
コード例 #5
0
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")
コード例 #6
0
ファイル: __init__.py プロジェクト: badele/fabrecipes
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")