)
ASTUTE_YAML = '/etc/fuel/astute.yaml'
-@@ -35,15 +39,47 @@ def parse_arguments():
+@@ -35,15 +39,45 @@ def parse_arguments():
check_file_exists(dea_file)
return dea_file
+ exec_cmd('echo "DEFROUTE=no" >> %s' % admin_ifcfg)
+ log('At least one interface was reconfigured, restart network manager')
+ exec_cmd('systemctl restart network')
-+ log('At least one interface was reconfigured, accept SSH on all')
-+ exec_cmd('iptables -A INPUT -p tcp --dport ssh -j ACCEPT')
return astute
@@ -51,11 +85,14 @@ def main():
- dea_file = parse_arguments()
check_file_exists(ASTUTE_YAML)
+ check_file_exists(FUEL_BOOTSTRAP_CLI_YAML)
dea = DeploymentEnvironmentAdapter(dea_file)
+ log('Reading astute file %s' % ASTUTE_YAML)
with io.open(ASTUTE_YAML) as stream:
with io.open(ASTUTE_YAML, 'w') as stream:
yaml.dump(astute, stream, default_flow_style=False)
+ log('Transplant done')
-
-
- if __name__ == '__main__':
+ # Update bootstrap config yaml with info from DEA/astute.yaml
+ with io.open(FUEL_BOOTSTRAP_CLI_YAML) as stream:
+ fuel_bootstrap_cli = yaml.load(stream)