• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/usr/bin/env python2
2
3"""
4Usage: ./print_host_labels.py <IP.or.hostname>
5"""
6
7import sys
8import common
9from autotest_lib.server.hosts import factory
10
11if len(sys.argv) < 2:
12    print 'Usage: %s <IP.or.hostname>' % sys.argv[0]
13    exit(1)
14
15host = factory.create_host(sys.argv[1])
16labels = host.get_labels()
17print 'Labels:'
18print labels
19