File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -56,14 +56,19 @@ def main():
5656 azure_template = get_file ("azure-user-data-template" )
5757 coreos_template = get_file ("../coreos/user-data.example" )
5858
59- configuration_coreos_template = yaml .safe_load (coreos_template )
59+ coreos_template_w_url = None
60+ with open (coreos_template .name , 'r' ) as file :
61+ coreos_template_w_url = file .read ()
62+
63+ coreos_template_w_url = coreos_template_w_url .replace ('#DISCOVERY_URL' , url )
64+
65+ configuration_coreos_template = yaml .safe_load (coreos_template_w_url )
6066 configuration_azure_template = yaml .safe_load (azure_template )
6167
6268 configuration = combine_dicts (configuration_coreos_template ,
6369 configuration_azure_template )
6470
6571 dump = yaml .dump (configuration , default_flow_style = False )
66- dump = dump .replace ('#DISCOVERY_URL' , url )
6772
6873 with azure_user_data as outfile :
6974 try :
You can’t perform that action at this time.
0 commit comments