Merge branch 'release' into dev
This commit is contained in:
commit
06e23558d2
|
|
@ -69,6 +69,8 @@ namespace Microsoft.AspNetCore.Server.Testing
|
|||
|
||||
public string ApplicationPath { get; set; }
|
||||
|
||||
public string TargetFramework { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// To publish the application before deployment.
|
||||
/// </summary>
|
||||
|
|
@ -76,8 +78,6 @@ namespace Microsoft.AspNetCore.Server.Testing
|
|||
|
||||
public ApplicationType ApplicationType { get; set; }
|
||||
|
||||
public string PublishTargetFramework { get; set; }
|
||||
|
||||
public string PublishedApplicationRootPath { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ namespace Microsoft.AspNetCore.Server.Testing
|
|||
|
||||
protected void DotnetPublish(string publishRoot = null)
|
||||
{
|
||||
if (string.IsNullOrEmpty(DeploymentParameters.PublishTargetFramework))
|
||||
if (string.IsNullOrEmpty(DeploymentParameters.TargetFramework))
|
||||
{
|
||||
throw new Exception($"A target framework must be specified in the deployment parameters for applications that require publishing before deployment");
|
||||
}
|
||||
|
|
@ -49,7 +49,7 @@ namespace Microsoft.AspNetCore.Server.Testing
|
|||
|
||||
var parameters = $"publish \"{DeploymentParameters.ApplicationPath}\""
|
||||
+ $" -o \"{DeploymentParameters.PublishedApplicationRootPath}\""
|
||||
+ $" --framework {DeploymentParameters.PublishTargetFramework}";
|
||||
+ $" --framework {DeploymentParameters.TargetFramework}";
|
||||
|
||||
Logger.LogInformation($"Executing command {DotnetCommandName} {parameters}");
|
||||
|
||||
|
|
|
|||
|
|
@ -74,8 +74,10 @@ namespace Microsoft.AspNetCore.Server.Testing
|
|||
}
|
||||
else
|
||||
{
|
||||
var targetFramework = DeploymentParameters.TargetFramework ?? (DeploymentParameters.RuntimeFlavor == RuntimeFlavor.Clr ? "net451" : "netcoreapp1.0");
|
||||
|
||||
executableName = DotnetCommandName;
|
||||
executableArgs = $"run -p \"{DeploymentParameters.ApplicationPath}\" {DotnetArgumentSeparator}";
|
||||
executableArgs = $"run -p \"{DeploymentParameters.ApplicationPath}\" --framework {targetFramework} {DotnetArgumentSeparator}";
|
||||
}
|
||||
|
||||
executableArgs += $" --server.urls {uri} "
|
||||
|
|
|
|||
Loading…
Reference in New Issue