def main():
    template_params = {'hostname': gethostname(), 'user': getuser(), 'cpus': cpu_count()}
    config_contents = Template(SLURM_CONFIG_TEMPLATE).substitute(template_params)
    open('/etc/slurm-llnl/slurm.conf', 'w').write(config_contents)
def main():
    template_params = {'hostname': gethostname(), 'user': getuser(), 'cpus': cpu_count()}
    config_contents = Template(SLURM_CONFIG_TEMPLATE).substitute(template_params)
    open('/etc/slurm-llnl/slurm.conf', 'w').write(config_contents)