Implemented in .NET Core 6 Minimal Api.
-
Make sure you have .NET Core 6 installed.
It may be already installed on your computer. You can view all .NET installations on your computer, by running:
dotnet --info -
Make sure you have sqlcmd installed, to allow queries to the database through the cli.
It may be already installed on your computer. You can check this by running:
sqlcmd -?
-
For SSMS And IIS
The IIS app (of "db-vcs-ci-server") that runs the "sqlcmd" command may not have credentials for managing the database. You should create a new "SQL Server Authentication" user in your SSMS, so your IIS app could use it to export the database through "sqlcmd".
- Follow this video for doing so.
- Make sure the "db-vcs-ci-client" use these credentials when using the "sqlcmd" command.
For debugging cmd window,
you can navigate to db-vcs-ci-server/Program.cs,
and in RunCmdCommand function change the lines from:
process.WindowStyle = ProcessWindowStyle.Hidden;
process.StartInfo.UseShellExecute = false;
process.StartInfo.RedirectStandardOutput = true;
process.StartInfo.RedirectStandardError = true;to
process.WindowStyle = ProcessWindowStyle.Normal;
process.StartInfo.UseShellExecute = true;
process.StartInfo.RedirectStandardOutput = false;
process.StartInfo.RedirectStandardError = false;and comment-out the lines:
string output = process.StandardOutput.ReadToEnd();
string err = process.StandardError.ReadToEnd();so you will view the cmd window launching.