Load Kubernetes incluster config instead
All checks were successful
continuous-integration/drone Build is passing
All checks were successful
continuous-integration/drone Build is passing
This commit is contained in:
parent
7510dc8b6f
commit
b378cfd75b
@ -19,7 +19,7 @@ from sanic_prometheus import monitor
|
||||
targets = [(j,j) for j in sys.argv[1:]]
|
||||
if not targets:
|
||||
# If no targets are specified, fall back to Kube API
|
||||
config.load_kube_config()
|
||||
config.load_incluster_config()
|
||||
v1 = client.CoreV1Api()
|
||||
for i in v1.list_namespaced_service("camtiler", label_selector="component=camdetect").items:
|
||||
app.ctx.frames[i.metadata.name] = None
|
||||
|
Loading…
Reference in New Issue
Block a user