- shutil.copy(os.path.join(TEMPLATES, 'ipsilon.conf'), CONFDIR)
- shutil.copy(os.path.join(TEMPLATES, 'idp.conf'), CONFDIR)
+ if not os.path.exists(instance_conf):
+ os.makedirs(instance_conf, 0700)
+ confopts = {'instance': args['instance'], 'datadir': args['data_dir']}
+ files.write_from_template(ipsilon_conf,
+ os.path.join(TEMPLATES, 'ipsilon.conf'),
+ confopts)
+ files.write_from_template(idp_conf,
+ os.path.join(TEMPLATES, 'idp.conf'),
+ confopts)