Add publishing for sdk, sharedhost, sharedfx deb files

small fix

disable dotnet-nightly train avoidance, alawys use the same debian config for now
This commit is contained in:
Bryan Thornbury 2016-03-22 14:14:54 -07:00
parent 1c38b17f8b
commit 96664f31c2
4 changed files with 48 additions and 10 deletions

View file

@ -33,10 +33,6 @@
"%SHARED_FRAMEWORK_DEBIAN_PACKAGE_NAME%" : {}
},
"package_conflicts" : [
"dotnet-dev-nightly"
],
"symlinks": {
"bin/dotnet-compile-native" : "/usr/bin/dotnet-compile-native"
}

View file

@ -168,7 +168,7 @@ namespace Microsoft.DotNet.Cli.Build
{
IEnumerable<string> orderedPackageNames = new List<string>()
{
Monikers.GetDebianPackageName(c),
Monikers.GetSdkDebianPackageName(c),
Monikers.GetDebianSharedFrameworkPackageName(c),
Monikers.GetDebianSharedHostPackageName(c)
};

View file

@ -47,7 +47,7 @@ namespace Microsoft.DotNet.Cli.Build
[Target(
nameof(PublishTargets.PublishVersionBadge),
nameof(PublishTargets.PublishSdkInstallerFile),
//nameof(PublishTargets.PublishDebFileToDebianRepo),
nameof(PublishTargets.PublishDebFilesToDebianRepo),
nameof(PublishTargets.PublishCombinedFrameworkSDKHostFile),
nameof(PublishTargets.PublishCombinedFrameworkHostFile),
nameof(PublishTargets.PublishLatestVersionTextFile))]
@ -93,11 +93,21 @@ namespace Microsoft.DotNet.Cli.Build
return c.Success();
}
[Target(nameof(PublishSdkInstallerFile))]
[Target(
nameof(PublishSdkDebToDebianRepo),
nameof(PublishSharedFrameworkDebToDebianRepo),
nameof(PublishSharedHostDebToDebianRepo))]
[BuildPlatforms(BuildPlatform.Ubuntu)]
public static BuildTargetResult PublishDebFileToDebianRepo(BuildTargetContext c)
public static BuildTargetResult PublishDebFilesToDebianRepo(BuildTargetContext c)
{
var packageName = Monikers.GetDebianPackageName(c);
return c.Success();
}
[Target]
[BuildPlatforms(BuildPlatform.Ubuntu)]
public static BuildTargetResult PublishSdkDebToDebianRepo(BuildTargetContext c)
{
var packageName = Monikers.GetSdkDebianPackageName(c);
var installerFile = c.BuildContext.Get<string>("SdkInstallerFile");
var uploadUrl = $"https://dotnetcli.blob.core.windows.net/dotnet/{Channel}/Installers/{Version}/{Path.GetFileName(installerFile)}";
var uploadJson = GenerateUploadJsonFile(packageName, Version, uploadUrl);
@ -109,6 +119,38 @@ namespace Microsoft.DotNet.Cli.Build
return c.Success();
}
[Target]
[BuildPlatforms(BuildPlatform.Ubuntu)]
public static BuildTargetResult PublishSharedFrameworkDebToDebianRepo(BuildTargetContext c)
{
var packageName = Monikers.GetDebianSharedFrameworkPackageName(c);
var installerFile = c.BuildContext.Get<string>("SharedFrameworkInstallerFile");
var uploadUrl = $"https://dotnetcli.blob.core.windows.net/dotnet/{Channel}/Installers/{Version}/{Path.GetFileName(installerFile)}";
var uploadJson = GenerateUploadJsonFile(packageName, Version, uploadUrl);
Cmd(Path.Combine(Dirs.RepoRoot, "scripts", "publish", "repoapi_client.sh"), "-addpkg", uploadJson)
.Execute()
.EnsureSuccessful();
return c.Success();
}
[Target]
[BuildPlatforms(BuildPlatform.Ubuntu)]
public static BuildTargetResult PublishSharedHostDebToDebianRepo(BuildTargetContext c)
{
var packageName = Monikers.GetDebianSharedHostPackageName(c);
var installerFile = c.BuildContext.Get<string>("SharedHostInstallerFile");
var uploadUrl = $"https://dotnetcli.blob.core.windows.net/dotnet/{Channel}/Installers/{Version}/{Path.GetFileName(installerFile)}";
var uploadJson = GenerateUploadJsonFile(packageName, Version, uploadUrl);
Cmd(Path.Combine(Dirs.RepoRoot, "scripts", "publish", "repoapi_client.sh"), "-addpkg", uploadJson)
.Execute()
.EnsureSuccessful();
return c.Success();
}
[Target]
[Environment("DOCKER_HUB_REPO")]
[Environment("DOCKER_HUB_TRIGGER_TOKEN")]

View file

@ -167,7 +167,7 @@ copy_files_to_debian_layout(){
cp -a "$REPO_BINARIES_DIR/." "$PACKAGE_LAYOUT_DIR/package_root"
# Copy config file
cp "$PACKAGING_ROOT/$DOTNET_DEB_PACKAGE_NAME-debian_config.json" "$PACKAGE_LAYOUT_DIR/debian_config.json"
cp "$PACKAGING_ROOT/dotnet-debian_config.json" "$PACKAGE_LAYOUT_DIR/debian_config.json"
# Copy Manpages
cp -a "$MANPAGE_DIR/." "$PACKAGE_LAYOUT_DIR/docs"