#!/usr/bin/python3
# coding: utf-8

import os
import json
from subprocess import check_call


check_call(['/usr/sbin/regenerate-monrun-tasks'], timeout=60)

# juggler сбрасывает весь environment, поэтому мы должны пересоздать окружение
with open('/environ.json', 'wt', encoding='utf-8') as f:
    json.dump(dict(os.environ), f, indent=2, ensure_ascii=False)
