Commit b6278767 authored by Marco Mariani's avatar Marco Mariani

sshkeys_authority: watch files with with sleep loop (no inotifyx)

parent 6ecd82c6
......@@ -31,7 +31,18 @@ import subprocess
import re
from slapos.recipe.librecipe import GenericBaseRecipe
from slapos.recipe.librecipe.inotify import subfiles
def subfiles(d):
import time
ret = set()
while True:
for f in os.listdir(d):
if not f in ret:
yield os.path.join(d, f)
ret.add(f)
time.sleep(2)
# This authority only works with dropbear sshkey generator
def sshkeys_authority(args):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment