From 1de9dbf18cd735eab646127e0f4c74e8918a5da6 Mon Sep 17 00:00:00 2001 From: Shannon Date: Mon, 30 Mar 2015 20:13:03 +1100 Subject: [PATCH] Updates build process to include building a nuget Identity package to provide extensibility points in Umbraco. --- LICENSE.md | 9 ----- build/Build.bat | 1 + build/Build.proj | 24 ++++++++++++++ build/NuSpecs/UmbracoCms.Identity.nuspec | 24 ++++++++++++++ src/Umbraco.Web.UI/App_Start/Readme.txt | 33 +++++++++++++++++++ ...Startup.cs => UmbracoCustomOwinStartup.cs} | 2 +- ...artup.cs => UmbracoStandardOwinStartup.cs} | 2 +- src/Umbraco.Web.UI/Umbraco.Web.UI.csproj | 4 +-- .../config/ClientDependency.config | 2 +- src/Umbraco.Web.UI/web.Template.Debug.config | 2 +- src/Umbraco.Web.UI/web.Template.config | 2 +- src/Umbraco.Web/Umbraco.Web.csproj | 2 +- ...tartup.cs => UmbracoDefaultOwinStartup.cs} | 4 +-- src/umbraco.sln | 1 + 14 files changed, 92 insertions(+), 20 deletions(-) delete mode 100644 LICENSE.md create mode 100644 build/NuSpecs/UmbracoCms.Identity.nuspec create mode 100644 src/Umbraco.Web.UI/App_Start/Readme.txt rename src/Umbraco.Web.UI/App_Start/{CustomUmbracoOwinStartup.cs => UmbracoCustomOwinStartup.cs} (97%) rename src/Umbraco.Web.UI/App_Start/{StandardUmbracoOwinStartup.cs => UmbracoStandardOwinStartup.cs} (96%) rename src/Umbraco.Web/{DefaultUmbracoOwinStartup.cs => UmbracoDefaultOwinStartup.cs} (90%) diff --git a/LICENSE.md b/LICENSE.md deleted file mode 100644 index 149435b7cb..0000000000 --- a/LICENSE.md +++ /dev/null @@ -1,9 +0,0 @@ -# The MIT License (MIT) # - -Copyright (c) 2013 Umbraco - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/build/Build.bat b/build/Build.bat index 1b715dcc15..7a464b422c 100644 --- a/build/Build.bat +++ b/build/Build.bat @@ -56,6 +56,7 @@ REN .\_BuildOutput\WebApp\Xslt\Web.config Web.config.transform ECHO Packing the NuGet release files ..\src\.nuget\NuGet.exe Pack NuSpecs\UmbracoCms.Core.nuspec -Version %version% ..\src\.nuget\NuGet.exe Pack NuSpecs\UmbracoCms.nuspec -Version %version% +..\src\.nuget\NuGet.exe Pack NuSpecs\UmbracoCms.Identity.nuspec IF ERRORLEVEL 1 GOTO :showerror diff --git a/build/Build.proj b/build/Build.proj index 5be460d09b..ab346f7438 100644 --- a/build/Build.proj +++ b/build/Build.proj @@ -88,6 +88,7 @@ $(BuildFolderAbsolutePath)WebApp\ $(BuildFolderRelativeToProjects)WebPi\ $(BuildFolderAbsolutePath)WebPi\ + $(BuildFolderAbsolutePath)IdentityTemplates\ @@ -157,6 +158,28 @@ + + + + + + + + + + + + + + + + + + @@ -266,6 +289,7 @@ + $(BUILD_RELEASE) diff --git a/build/NuSpecs/UmbracoCms.Identity.nuspec b/build/NuSpecs/UmbracoCms.Identity.nuspec new file mode 100644 index 0000000000..c635b891f7 --- /dev/null +++ b/build/NuSpecs/UmbracoCms.Identity.nuspec @@ -0,0 +1,24 @@ + + + + UmbracoCms.Identity + 1.0.0 + Umbraco Extensibility for ASP.Net Identity + Umbraco HQ + Umbraco HQ + http://opensource.org/licenses/MIT + http://umbraco.com/ + http://umbraco.com/media/357769/100px_transparent.png + false + Installs files/classes to help with ASP.Net Identity extensibility for Umbraco back office + Installs classes to help with ASP.Net Identity extensibility for Umbraco + en-US + umbraco aspnet identity + + + + + + + + \ No newline at end of file diff --git a/src/Umbraco.Web.UI/App_Start/Readme.txt b/src/Umbraco.Web.UI/App_Start/Readme.txt new file mode 100644 index 0000000000..b8897a27ea --- /dev/null +++ b/src/Umbraco.Web.UI/App_Start/Readme.txt @@ -0,0 +1,33 @@ + + _ _ __ __ ____ _____ _____ ____ + | | | | \/ | _ \| __ \ /\ / ____/ __ \ + | | | | \ / | |_) | |__) | / \ | | | | | | + | | | | |\/| | _ <| _ / / /\ \| | | | | | + | |__| | | | | |_) | | \ \ / ____ | |___| |__| | + \____/|_| |_|____/|_| \_/_/ \_\_____\____/ + +---------------------------------------------------- + +Umbraco extensibility code has been installed for ASP.Net Identity with Umbraco back office users + +The files have been installed into your App_Start folder if you have a Web Application project +or into App_Code if you have a Website project. + +All of these files include lots of code comments, documentation & notes to assist with extending +the ASP.Net Identity implementaion for back office users in Umbraco. For all 3rd party +ASP.Net providers, their dependencies will need to be manually installed. See comments in the +following files for full details: + +* StandardUmbracoOwinStartup.cs Includes code snippets to enable 3rd party ASP.Net Identity + providers to work with the Umbraco back office. + To enable the 'StandardUmbracoOwinStartup', update the web.config + appSetting "owin:appStartup" to be: "StandardUmbracoOwinStartup" + +* UmbracoCustomOwinStartup Includes code snippets to customize the Umbraco ASP.Net + Identity implementation for back office users as well as + snippets to enable 3rd party ASP.Net Identity providers to work. + To enable the 'UmbracoCustomOwinStartup', update the web.config + appSetting "owin:appStartup" to be: "UmbracoCustomOwinStartup" + +* UmbracoBackOfficeAuthExtensions Includes extension methods snippets to enable 3rd party ASP.Net + Identity providers to work with the Umbraco back office. \ No newline at end of file diff --git a/src/Umbraco.Web.UI/App_Start/CustomUmbracoOwinStartup.cs b/src/Umbraco.Web.UI/App_Start/UmbracoCustomOwinStartup.cs similarity index 97% rename from src/Umbraco.Web.UI/App_Start/CustomUmbracoOwinStartup.cs rename to src/Umbraco.Web.UI/App_Start/UmbracoCustomOwinStartup.cs index 6769b760a9..a50e50fa1e 100644 --- a/src/Umbraco.Web.UI/App_Start/CustomUmbracoOwinStartup.cs +++ b/src/Umbraco.Web.UI/App_Start/UmbracoCustomOwinStartup.cs @@ -5,7 +5,7 @@ using Umbraco.Core.Security; using Umbraco.Web.Security.Identity; using Umbraco.Web.UI; -[assembly: OwinStartup("CustomUmbracoStartup", typeof(StandardUmbracoOwinStartup))] +[assembly: OwinStartup("CustomUmbracoOwinStartup", typeof(StandardUmbracoOwinStartup))] namespace Umbraco.Web.UI { diff --git a/src/Umbraco.Web.UI/App_Start/StandardUmbracoOwinStartup.cs b/src/Umbraco.Web.UI/App_Start/UmbracoStandardOwinStartup.cs similarity index 96% rename from src/Umbraco.Web.UI/App_Start/StandardUmbracoOwinStartup.cs rename to src/Umbraco.Web.UI/App_Start/UmbracoStandardOwinStartup.cs index a684efa2be..0c7a06d0f5 100644 --- a/src/Umbraco.Web.UI/App_Start/StandardUmbracoOwinStartup.cs +++ b/src/Umbraco.Web.UI/App_Start/UmbracoStandardOwinStartup.cs @@ -5,7 +5,7 @@ using Umbraco.Core.Security; using Umbraco.Web.Security.Identity; using Umbraco.Web.UI; -[assembly: OwinStartup("StandardUmbracoStartup", typeof(StandardUmbracoOwinStartup))] +[assembly: OwinStartup("StandardUmbracoOwinStartup", typeof(StandardUmbracoOwinStartup))] namespace Umbraco.Web.UI { diff --git a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj index ee56ec0fef..8d2c185043 100644 --- a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj +++ b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj @@ -357,9 +357,6 @@ Properties\SolutionInfo.cs - - - loadStarterKits.ascx ASPXCodeBehind @@ -2557,6 +2554,7 @@ + diff --git a/src/Umbraco.Web.UI/config/ClientDependency.config b/src/Umbraco.Web.UI/config/ClientDependency.config index 246bff7cac..7b53338f12 100644 --- a/src/Umbraco.Web.UI/config/ClientDependency.config +++ b/src/Umbraco.Web.UI/config/ClientDependency.config @@ -10,7 +10,7 @@ NOTES: * Compression/Combination/Minification is not enabled unless debug="false" is specified on the 'compiliation' element in the web.config * A new version will invalidate both client and server cache and create new persisted files --> - +