Console.WriteLine("Replaced \""+string.Join(";",listenKeys.Select(x=>x.Key+"="+x.Value).ToArray())+"\" with \""+string.Join(";",currentValues.Select(x=>x.Key+"="+x.Value).ToArray())+"\" in \""+outputConfigFile+"\"");
}
}
else
else
{
{
Console.WriteLine("Please call \"SetValueOnConfiguration\" with \"Key\", \"ConfigurationFile\" and \"ReplaceKey\"");
Console.WriteLine("Please call \"SetValueOnConfiguration\" with \"TemplateConfigurationFile\", \"OutputConfigurationFile\" and n-combinations of \"ReplaceKey\" and \"ConsulKey\"");
}
}
break;
break;
case"RestartNomadJob":
case"RestartNomadJob":
...
@@ -67,8 +75,55 @@ namespace ConfigurationUpdater
...
@@ -67,8 +75,55 @@ namespace ConfigurationUpdater
Console.WriteLine("Please call \"RestartNomadJob\" with the \"JobId\"");
Console.WriteLine("Please call \"RestartNomadJob\" with the \"JobId\"");
Console.WriteLine("Replaced \""+string.Join(";",listenKeys.Select(x=>x.Key+"="+x.Value).ToArray())+"\" with \""+string.Join(";",currentValues.Select(x=>x.Key+"="+x.Value).ToArray())+"\" in \""+outputConfigFile+"\"");
Console.WriteLine("Replaced \""+string.Join(";",listenKeys.Select(x=>x.Key+"="+x.Value).ToArray())+"\" with \""+string.Join(";",currentValues.Select(x=>x.Key+"="+x.Value).ToArray())+"\" in \""+outputConfigFile+"\"");
}
}
}
else
{
Console.WriteLine("Please call \"Listen\" with \"JobId\", \"TemplateConfigurationFile\", \"OutputConfigurationFile\" and n-combinations of \"ReplaceKey\" and \"ConsulKey\"");
}
break;
default:
default:
Console.WriteLine("Please call this program with the method \"SetValue\", \"GetValue\", \"SetValueOnConfiguration\" or \"RestartNomadJob\"");
Console.WriteLine("Please call this program with the method \"SetValue\", \"GetValue\", \"SetValueOnConfiguration\", \"RestartNomadJob\" or \"Listen\"");