File: server_example.py

package info (click to toggle)
python-seamicroclient 0.4.0%2B2016.05.20.git.40ee44c664-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 452 kB
  • sloc: python: 2,093; sh: 134; makefile: 15
file content (11 lines) | stat: -rw-r--r-- 231 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
import json

from seamicroclient.v2 import client

seamicro = client.Client("admin", "seamicro", "http://172.16.0.25/v2.0")

servers = seamicro.servers.list()

for server in servers:
    print(json.dumps(server))
    print("\n\n")