1
0
mirror of https://github.com/altlinux/gpupdate.git synced 2025-03-21 18:50:38 +03:00

Browser appliers: create settings destination directory if not exists

This commit is contained in:
Игорь Чудов 2019-12-04 17:56:31 +04:00
parent fcae9879da
commit b8693d4005
Signed by untrusted user: nir
GPG Key ID: 0F3883600CAE7AAC
2 changed files with 2 additions and 0 deletions

View File

@ -36,6 +36,7 @@ class chromium_applier(applier_frontend):
destfile = os.path.join(self.__managed_policies_path, 'policies.json')
os.makedirs(self.__managed_policies_path, exist_ok=True)
with open(destfile, 'w') as f:
json.dump(self.policies, f)
logging.info('Wrote Chromium preferences to {}'.format(destfile))

View File

@ -80,6 +80,7 @@ class firefox_applier(applier_frontend):
destfile = os.path.join(self.__firefox_installdir, 'policies.json')
os.makedirs(self.__firefox_installdir, exist_ok=True)
with open(destfile, 'w') as f:
json.dump(self.policies_json, f)
logging.info('Wrote Firefox preferences to {}'.format(destfile))