Add generated kind config #623

Merged
telackey merged 7 commits from dboreham/kind-config into main 2023-11-06 06:21:54 +00:00
2 changed files with 4 additions and 2 deletions
Showing only changes of commit 15f59b5b1b - Show all commits

View File

@ -369,7 +369,8 @@ def create(ctx, spec_file, deployment_dir, network_dir, initial_peers):
deployment_context = DeploymentContext(Path(deployment_dir), deployment_command_context)
# Call the deployer to generate any deployer-specific files (e.g. for kind)
deployer_config_generator = getDeployerConfigGenerator(parsed_spec["deploy-to"])
deployer_config_generator.generate(deployment_dir)
# TODO: make deployment_dir a Path above
deployer_config_generator.generate(Path(deployment_dir))
call_stack_deploy_create(deployment_context, [network_dir, initial_peers])

View File

@ -121,6 +121,7 @@ class K8sDeployerConfigGenerator(DeployerConfigGenerator):
# Check the file isn't already there
# Get the config file contents
content = generate_kind_config()
config_file = deployment_dir.joinpath(self.config_file_name)
# Write the file
with open(deployment_dir, "w") as output_file:
with open(config_file, "w") as output_file:
output_file.write(content)