mirror of
https://github.com/ceph/ceph
synced 2025-01-31 07:22:56 +00:00
ad278fdc71
Signed-off-by: Zack Cerza <zack.cerza@inktank.com>
15 lines
351 B
Python
15 lines
351 B
Python
import requests
|
|
import os
|
|
from .config import config
|
|
from .misc import canonicalize_hostname
|
|
|
|
|
|
def get_status(name):
|
|
name = canonicalize_hostname(name, user=None)
|
|
uri = os.path.join(config.lock_server, 'nodes', name, '')
|
|
response = requests.get(uri)
|
|
success = response.ok
|
|
if success:
|
|
return response.json()
|
|
return None
|