├── .gitignore ├── README.md ├── docker-cloud ├── README.md └── images │ ├── build_status.png │ ├── building.png │ ├── byon_button.png │ ├── byon_success.png │ ├── create-first-service.png │ ├── edit_repo.png │ ├── first-service-container-list.png │ ├── first-service-container.png │ ├── first-service-create-and-deploy-button.png │ ├── first-service-ports.png │ ├── first-service-timeline.png │ ├── first-service-webpage.png │ ├── first-service-wizard.png │ ├── first_node.png │ ├── node-byoh-wizard-v2.png │ ├── port_8080.jpg │ ├── power_socket.jpg │ ├── repositories.png │ ├── results.png │ ├── service_deployed.png │ ├── services_icon.png │ ├── stack_running.png │ ├── stacks_icon.png │ ├── timeline.png │ ├── update-automated-build.png │ ├── voting.png │ ├── welcome_node_create.png │ ├── wrench.jpg │ └── wrench.png ├── docker-enterprise ├── README.md └── images │ ├── HRM.png │ ├── animal.png │ ├── deploy-button.png │ ├── deploy.png │ ├── deploy2.png │ ├── exposed-port.png │ ├── health.png │ ├── hosts.png │ ├── kill.png │ ├── login.png │ ├── logs.png │ ├── multitenant.png │ ├── node-kill.png │ ├── paas-broken.png │ ├── password.png │ ├── pause.png │ ├── pets-dev-arch.png │ ├── pets-prod-arch.png │ ├── private.png │ ├── published-port-viz.png │ ├── published-port.png │ ├── removal.png │ ├── results.png │ ├── rollback.png │ ├── rolling.png │ ├── routing-mesh.png │ ├── safety.png │ ├── scaling.png │ ├── secret-create.png │ ├── secret.png │ ├── single-container-deploy.png │ ├── singletenant.png │ ├── stack.png │ ├── tasks.png │ ├── ucp-login.png │ ├── visualizer.png │ ├── viz.png │ └── voting.png ├── docker-networking └── README.md ├── docker-orchestration └── README.md ├── images └── dockercon.png ├── securing-apps-docker-enterprise ├── README.md └── images │ ├── HRM.png │ ├── animal.png │ ├── clean.png │ ├── components.png │ ├── deploy.png │ ├── dtr-home.png │ ├── dtr-repo.png │ ├── health.png │ ├── kill.png │ ├── layers.png │ ├── login.png │ ├── logs.png │ ├── multitenant.png │ ├── node-kill.png │ ├── paas-broken.png │ ├── pause.png │ ├── paypal.png │ ├── pets-dev-arch.png │ ├── pets-prod-arch.png │ ├── published-port.png │ ├── results.png │ ├── rollback.png │ ├── scaling.png │ ├── scan-status.png │ ├── secret.png │ ├── single-container-deploy.png │ ├── singletenant.png │ ├── stack.png │ ├── tasks.png │ ├── ucp-login.png │ ├── visualizer.png │ ├── viz.png │ └── voting.png ├── template.md ├── windows-101 ├── README.md ├── images │ ├── iis.png │ └── tweet-app.png └── tweet-app │ ├── Dockerfile │ ├── index.html │ └── start.ps1 ├── windows-modernize-aspnet-dev ├── .gitignore ├── README.md ├── images │ ├── app-v1.png │ ├── v1-arch.png │ └── v2-arch.png ├── v1-src │ ├── ProductLaunch │ │ ├── ProductLaunch.Core │ │ │ ├── Env.cs │ │ │ ├── ProductLaunch.Core.csproj │ │ │ └── Properties │ │ │ │ └── AssemblyInfo.cs │ │ ├── ProductLaunch.EndToEndTests │ │ │ ├── App.config │ │ │ ├── ProductLaunch.EndToEndTests.csproj │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ ├── ProspectSignUp.feature │ │ │ ├── ProspectSignUp.feature.cs │ │ │ ├── ProspectSignUpSteps.cs │ │ │ └── packages.config │ │ ├── ProductLaunch.Entities │ │ │ ├── Country.cs │ │ │ ├── ProductLaunch.Entities.csproj │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ ├── Prospect.cs │ │ │ └── Role.cs │ │ ├── ProductLaunch.MessageHandlers.IndexProspect │ │ │ ├── App.config │ │ │ ├── Config.cs │ │ │ ├── Documents │ │ │ │ └── Prospect.cs │ │ │ ├── Indexer │ │ │ │ └── Index.cs │ │ │ ├── ProductLaunch.MessageHandlers.IndexProspect.csproj │ │ │ ├── Program.cs │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ └── packages.config │ │ ├── ProductLaunch.MessageHandlers.SaveProspect │ │ │ ├── App.config │ │ │ ├── ProductLaunch.MessageHandlers.SaveProspect.csproj │ │ │ ├── Program.cs │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ └── packages.config │ │ ├── ProductLaunch.Messaging │ │ │ ├── Config.cs │ │ │ ├── MessageHelper.cs │ │ │ ├── MessageQueue.cs │ │ │ ├── Messages │ │ │ │ ├── Events │ │ │ │ │ └── ProspectSignedUpEvent.cs │ │ │ │ └── Message.cs │ │ │ ├── ProductLaunch.Messaging.csproj │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ └── packages.config │ │ ├── ProductLaunch.Model.Tests │ │ │ ├── App.config │ │ │ ├── ProductLaunch.Model.Tests.csproj │ │ │ ├── ProductLaunchContextTest.cs │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ └── packages.config │ │ ├── ProductLaunch.Model │ │ │ ├── App.config │ │ │ ├── Initializers │ │ │ │ └── StaticDataInitializer.cs │ │ │ ├── ProductLaunch.Model.csproj │ │ │ ├── ProductLaunchContext.cs │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ └── packages.config │ │ ├── ProductLaunch.Web │ │ │ ├── About.aspx │ │ │ ├── About.aspx.cs │ │ │ ├── About.aspx.designer.cs │ │ │ ├── App_Start │ │ │ │ ├── BundleConfig.cs │ │ │ │ └── RouteConfig.cs │ │ │ ├── ApplicationInsights.config │ │ │ ├── Bundle.config │ │ │ ├── Config.cs │ │ │ ├── Contact.aspx │ │ │ ├── Contact.aspx.cs │ │ │ ├── Contact.aspx.designer.cs │ │ │ ├── Content │ │ │ │ ├── Site.css │ │ │ │ ├── bootstrap.css │ │ │ │ └── bootstrap.min.css │ │ │ ├── Default.aspx │ │ │ ├── Default.aspx.cs │ │ │ ├── Default.aspx.designer.cs │ │ │ ├── Global.asax │ │ │ ├── Global.asax.cs │ │ │ ├── ProductLaunch.Web.csproj │ │ │ ├── Project_Readme.html │ │ │ ├── Properties │ │ │ │ └── AssemblyInfo.cs │ │ │ ├── Scripts │ │ │ │ ├── WebForms │ │ │ │ │ ├── DetailsView.js │ │ │ │ │ ├── Focus.js │ │ │ │ │ ├── GridView.js │ │ │ │ │ ├── MSAjax │ │ │ │ │ │ ├── MicrosoftAjax.js │ │ │ │ │ │ ├── MicrosoftAjaxApplicationServices.js │ │ │ │ │ │ ├── MicrosoftAjaxComponentModel.js │ │ │ │ │ │ ├── MicrosoftAjaxCore.js │ │ │ │ │ │ ├── MicrosoftAjaxGlobalization.js │ │ │ │ │ │ ├── MicrosoftAjaxHistory.js │ │ │ │ │ │ ├── MicrosoftAjaxNetwork.js │ │ │ │ │ │ ├── MicrosoftAjaxSerialization.js │ │ │ │ │ │ ├── MicrosoftAjaxTimer.js │ │ │ │ │ │ ├── MicrosoftAjaxWebForms.js │ │ │ │ │ │ └── MicrosoftAjaxWebServices.js │ │ │ │ │ ├── Menu.js │ │ │ │ │ ├── MenuStandards.js │ │ │ │ │ ├── SmartNav.js │ │ │ │ │ ├── TreeView.js │ │ │ │ │ ├── WebForms.js │ │ │ │ │ ├── WebParts.js │ │ │ │ │ └── WebUIValidation.js │ │ │ │ ├── _references.js │ │ │ │ ├── bootstrap.js │ │ │ │ ├── bootstrap.min.js │ │ │ │ ├── jquery-1.10.2.intellisense.js │ │ │ │ ├── jquery-1.10.2.js │ │ │ │ ├── jquery-1.10.2.min.js │ │ │ │ ├── jquery-1.10.2.min.map │ │ │ │ ├── modernizr-2.6.2.js │ │ │ │ ├── respond.js │ │ │ │ └── respond.min.js │ │ │ ├── SignUp.aspx │ │ │ ├── SignUp.aspx.cs │ │ │ ├── SignUp.aspx.designer.cs │ │ │ ├── Site.Master │ │ │ ├── Site.Master.cs │ │ │ ├── Site.Master.designer.cs │ │ │ ├── Site.Mobile.Master │ │ │ ├── Site.Mobile.Master.cs │ │ │ ├── Site.Mobile.Master.designer.cs │ │ │ ├── ThankYou.aspx │ │ │ ├── ThankYou.aspx.cs │ │ │ ├── ThankYou.aspx.designer.cs │ │ │ ├── ViewSwitcher.ascx │ │ │ ├── ViewSwitcher.ascx.cs │ │ │ ├── ViewSwitcher.ascx.designer.cs │ │ │ ├── Web.Debug.config │ │ │ ├── Web.Release.config │ │ │ ├── Web.config │ │ │ ├── favicon.ico │ │ │ ├── fonts │ │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ │ └── glyphicons-halflings-regular.woff │ │ │ └── packages.config │ │ ├── ProductLaunch.sln │ │ └── build.ps1 │ ├── build.ps1 │ └── docker │ │ ├── builder │ │ └── Dockerfile │ │ └── web │ │ ├── Dockerfile │ │ └── Web.config └── v2-src │ ├── ProductLaunch │ ├── ProductLaunch.Core │ │ ├── Env.cs │ │ ├── ProductLaunch.Core.csproj │ │ └── Properties │ │ │ └── AssemblyInfo.cs │ ├── ProductLaunch.EndToEndTests │ │ ├── App.config │ │ ├── ProductLaunch.EndToEndTests.csproj │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ ├── ProspectSignUp.feature │ │ ├── ProspectSignUp.feature.cs │ │ ├── ProspectSignUpSteps.cs │ │ └── packages.config │ ├── ProductLaunch.Entities │ │ ├── Country.cs │ │ ├── ProductLaunch.Entities.csproj │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ ├── Prospect.cs │ │ └── Role.cs │ ├── ProductLaunch.MessageHandlers.IndexProspect │ │ ├── App.config │ │ ├── Config.cs │ │ ├── Documents │ │ │ └── Prospect.cs │ │ ├── Indexer │ │ │ └── Index.cs │ │ ├── ProductLaunch.MessageHandlers.IndexProspect.csproj │ │ ├── Program.cs │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ └── packages.config │ ├── ProductLaunch.MessageHandlers.SaveProspect │ │ ├── App.config │ │ ├── ProductLaunch.MessageHandlers.SaveProspect.csproj │ │ ├── Program.cs │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ └── packages.config │ ├── ProductLaunch.Messaging │ │ ├── Config.cs │ │ ├── MessageHelper.cs │ │ ├── MessageQueue.cs │ │ ├── Messages │ │ │ ├── Events │ │ │ │ └── ProspectSignedUpEvent.cs │ │ │ └── Message.cs │ │ ├── ProductLaunch.Messaging.csproj │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ └── packages.config │ ├── ProductLaunch.Model.Tests │ │ ├── App.config │ │ ├── ProductLaunch.Model.Tests.csproj │ │ ├── ProductLaunchContextTest.cs │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ └── packages.config │ ├── ProductLaunch.Model │ │ ├── App.config │ │ ├── Config.cs │ │ ├── Initializers │ │ │ └── StaticDataInitializer.cs │ │ ├── ProductLaunch.Model.csproj │ │ ├── ProductLaunchContext.cs │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ └── packages.config │ ├── ProductLaunch.Web │ │ ├── About.aspx │ │ ├── About.aspx.cs │ │ ├── About.aspx.designer.cs │ │ ├── App_Start │ │ │ ├── BundleConfig.cs │ │ │ └── RouteConfig.cs │ │ ├── ApplicationInsights.config │ │ ├── Bundle.config │ │ ├── Contact.aspx │ │ ├── Contact.aspx.cs │ │ ├── Contact.aspx.designer.cs │ │ ├── Content │ │ │ ├── Site.css │ │ │ ├── bootstrap.css │ │ │ └── bootstrap.min.css │ │ ├── Default.aspx │ │ ├── Default.aspx.cs │ │ ├── Default.aspx.designer.cs │ │ ├── Global.asax │ │ ├── Global.asax.cs │ │ ├── ProductLaunch.Web.csproj │ │ ├── Project_Readme.html │ │ ├── Properties │ │ │ └── AssemblyInfo.cs │ │ ├── Scripts │ │ │ ├── WebForms │ │ │ │ ├── DetailsView.js │ │ │ │ ├── Focus.js │ │ │ │ ├── GridView.js │ │ │ │ ├── MSAjax │ │ │ │ │ ├── MicrosoftAjax.js │ │ │ │ │ ├── MicrosoftAjaxApplicationServices.js │ │ │ │ │ ├── MicrosoftAjaxComponentModel.js │ │ │ │ │ ├── MicrosoftAjaxCore.js │ │ │ │ │ ├── MicrosoftAjaxGlobalization.js │ │ │ │ │ ├── MicrosoftAjaxHistory.js │ │ │ │ │ ├── MicrosoftAjaxNetwork.js │ │ │ │ │ ├── MicrosoftAjaxSerialization.js │ │ │ │ │ ├── MicrosoftAjaxTimer.js │ │ │ │ │ ├── MicrosoftAjaxWebForms.js │ │ │ │ │ └── MicrosoftAjaxWebServices.js │ │ │ │ ├── Menu.js │ │ │ │ ├── MenuStandards.js │ │ │ │ ├── SmartNav.js │ │ │ │ ├── TreeView.js │ │ │ │ ├── WebForms.js │ │ │ │ ├── WebParts.js │ │ │ │ └── WebUIValidation.js │ │ │ ├── _references.js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ ├── jquery-1.10.2.intellisense.js │ │ │ ├── jquery-1.10.2.js │ │ │ ├── jquery-1.10.2.min.js │ │ │ ├── jquery-1.10.2.min.map │ │ │ ├── modernizr-2.6.2.js │ │ │ ├── respond.js │ │ │ └── respond.min.js │ │ ├── SignUp.aspx │ │ ├── SignUp.aspx.cs │ │ ├── SignUp.aspx.designer.cs │ │ ├── Site.Master │ │ ├── Site.Master.cs │ │ ├── Site.Master.designer.cs │ │ ├── Site.Mobile.Master │ │ ├── Site.Mobile.Master.cs │ │ ├── Site.Mobile.Master.designer.cs │ │ ├── ThankYou.aspx │ │ ├── ThankYou.aspx.cs │ │ ├── ThankYou.aspx.designer.cs │ │ ├── ViewSwitcher.ascx │ │ ├── ViewSwitcher.ascx.cs │ │ ├── ViewSwitcher.ascx.designer.cs │ │ ├── Web.Debug.config │ │ ├── Web.Release.config │ │ ├── Web.config │ │ ├── favicon.ico │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ └── glyphicons-halflings-regular.woff │ │ └── packages.config │ ├── ProductLaunch.sln │ └── build.ps1 │ ├── build.ps1 │ ├── docker-compose.yml │ └── docker │ ├── builder │ └── Dockerfile │ ├── save-prospect │ └── Dockerfile │ └── web │ ├── Dockerfile │ └── bootstrap.ps1 └── windows-modernize-aspnet-ops ├── README.md ├── images ├── app-v1.0.png └── app-v1.1.png ├── v1.0 ├── Dockerfile └── UpgradeSample-1.0.0.0.msi └── v1.1 ├── Dockerfile └── UpgradeSample-1.1.0.0.msi /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | *.swp 3 | -------------------------------------------------------------------------------- /docker-cloud/images/build_status.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/build_status.png -------------------------------------------------------------------------------- /docker-cloud/images/building.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/building.png -------------------------------------------------------------------------------- /docker-cloud/images/byon_button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/byon_button.png -------------------------------------------------------------------------------- /docker-cloud/images/byon_success.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/byon_success.png -------------------------------------------------------------------------------- /docker-cloud/images/create-first-service.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/create-first-service.png -------------------------------------------------------------------------------- /docker-cloud/images/edit_repo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/edit_repo.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-container-list.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-container-list.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-container.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-container.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-create-and-deploy-button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-create-and-deploy-button.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-ports.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-ports.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-timeline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-timeline.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-webpage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-webpage.png -------------------------------------------------------------------------------- /docker-cloud/images/first-service-wizard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first-service-wizard.png -------------------------------------------------------------------------------- /docker-cloud/images/first_node.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/first_node.png -------------------------------------------------------------------------------- /docker-cloud/images/node-byoh-wizard-v2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/node-byoh-wizard-v2.png -------------------------------------------------------------------------------- /docker-cloud/images/port_8080.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/port_8080.jpg -------------------------------------------------------------------------------- /docker-cloud/images/power_socket.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/power_socket.jpg -------------------------------------------------------------------------------- /docker-cloud/images/repositories.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/repositories.png -------------------------------------------------------------------------------- /docker-cloud/images/results.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/results.png -------------------------------------------------------------------------------- /docker-cloud/images/service_deployed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/service_deployed.png -------------------------------------------------------------------------------- /docker-cloud/images/services_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/services_icon.png -------------------------------------------------------------------------------- /docker-cloud/images/stack_running.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/stack_running.png -------------------------------------------------------------------------------- /docker-cloud/images/stacks_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/stacks_icon.png -------------------------------------------------------------------------------- /docker-cloud/images/timeline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/timeline.png -------------------------------------------------------------------------------- /docker-cloud/images/update-automated-build.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/update-automated-build.png -------------------------------------------------------------------------------- /docker-cloud/images/voting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/voting.png -------------------------------------------------------------------------------- /docker-cloud/images/welcome_node_create.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/welcome_node_create.png -------------------------------------------------------------------------------- /docker-cloud/images/wrench.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/wrench.jpg -------------------------------------------------------------------------------- /docker-cloud/images/wrench.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-cloud/images/wrench.png -------------------------------------------------------------------------------- /docker-enterprise/images/HRM.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/HRM.png -------------------------------------------------------------------------------- /docker-enterprise/images/animal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/animal.png -------------------------------------------------------------------------------- /docker-enterprise/images/deploy-button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/deploy-button.png -------------------------------------------------------------------------------- /docker-enterprise/images/deploy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/deploy.png -------------------------------------------------------------------------------- /docker-enterprise/images/deploy2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/deploy2.png -------------------------------------------------------------------------------- /docker-enterprise/images/exposed-port.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/exposed-port.png -------------------------------------------------------------------------------- /docker-enterprise/images/health.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/health.png -------------------------------------------------------------------------------- /docker-enterprise/images/hosts.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/hosts.png -------------------------------------------------------------------------------- /docker-enterprise/images/kill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/kill.png -------------------------------------------------------------------------------- /docker-enterprise/images/login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/login.png -------------------------------------------------------------------------------- /docker-enterprise/images/logs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/logs.png -------------------------------------------------------------------------------- /docker-enterprise/images/multitenant.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/multitenant.png -------------------------------------------------------------------------------- /docker-enterprise/images/node-kill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/node-kill.png -------------------------------------------------------------------------------- /docker-enterprise/images/paas-broken.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/paas-broken.png -------------------------------------------------------------------------------- /docker-enterprise/images/password.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/password.png -------------------------------------------------------------------------------- /docker-enterprise/images/pause.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/pause.png -------------------------------------------------------------------------------- /docker-enterprise/images/pets-dev-arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/pets-dev-arch.png -------------------------------------------------------------------------------- /docker-enterprise/images/pets-prod-arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/pets-prod-arch.png -------------------------------------------------------------------------------- /docker-enterprise/images/private.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/private.png -------------------------------------------------------------------------------- /docker-enterprise/images/published-port-viz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/published-port-viz.png -------------------------------------------------------------------------------- /docker-enterprise/images/published-port.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/published-port.png -------------------------------------------------------------------------------- /docker-enterprise/images/removal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/removal.png -------------------------------------------------------------------------------- /docker-enterprise/images/results.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/results.png -------------------------------------------------------------------------------- /docker-enterprise/images/rollback.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/rollback.png -------------------------------------------------------------------------------- /docker-enterprise/images/rolling.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/rolling.png -------------------------------------------------------------------------------- /docker-enterprise/images/routing-mesh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/routing-mesh.png -------------------------------------------------------------------------------- /docker-enterprise/images/safety.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/safety.png -------------------------------------------------------------------------------- /docker-enterprise/images/scaling.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/scaling.png -------------------------------------------------------------------------------- /docker-enterprise/images/secret-create.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/secret-create.png -------------------------------------------------------------------------------- /docker-enterprise/images/secret.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/secret.png -------------------------------------------------------------------------------- /docker-enterprise/images/single-container-deploy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/single-container-deploy.png -------------------------------------------------------------------------------- /docker-enterprise/images/singletenant.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/singletenant.png -------------------------------------------------------------------------------- /docker-enterprise/images/stack.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/stack.png -------------------------------------------------------------------------------- /docker-enterprise/images/tasks.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/tasks.png -------------------------------------------------------------------------------- /docker-enterprise/images/ucp-login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/ucp-login.png -------------------------------------------------------------------------------- /docker-enterprise/images/visualizer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/visualizer.png -------------------------------------------------------------------------------- /docker-enterprise/images/viz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/viz.png -------------------------------------------------------------------------------- /docker-enterprise/images/voting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/docker-enterprise/images/voting.png -------------------------------------------------------------------------------- /images/dockercon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/images/dockercon.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/HRM.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/HRM.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/animal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/animal.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/clean.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/clean.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/components.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/components.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/deploy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/deploy.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/dtr-home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/dtr-home.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/dtr-repo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/dtr-repo.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/health.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/health.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/kill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/kill.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/layers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/layers.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/login.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/logs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/logs.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/multitenant.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/multitenant.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/node-kill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/node-kill.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/paas-broken.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/paas-broken.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/pause.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/pause.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/paypal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/paypal.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/pets-dev-arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/pets-dev-arch.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/pets-prod-arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/pets-prod-arch.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/published-port.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/published-port.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/results.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/results.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/rollback.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/rollback.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/scaling.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/scaling.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/scan-status.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/scan-status.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/secret.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/secret.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/single-container-deploy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/single-container-deploy.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/singletenant.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/singletenant.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/stack.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/stack.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/tasks.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/tasks.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/ucp-login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/ucp-login.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/visualizer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/visualizer.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/viz.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/viz.png -------------------------------------------------------------------------------- /securing-apps-docker-enterprise/images/voting.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/securing-apps-docker-enterprise/images/voting.png -------------------------------------------------------------------------------- /template.md: -------------------------------------------------------------------------------- 1 | # Lab X: Lab Title 2 | 3 | Quick description of the lab. 4 | 5 | > **Difficulty**: Beginner | Intermediate | Advanced 6 | 7 | > **Time**: Approximately XX minutes 8 | 9 | > **Tasks**: 10 | > 11 | > * [Prerequisites](#prerequisites) 12 | > * [Task 1](#task1) 13 | > * [Task 2](#task2) 14 | 15 | ## Document conventions 16 | 17 | When you encounter a phrase in between `<` and `>` you are meant to substitute in a different value. 18 | 19 | For instance if you see `ssh @` you would actually type something like `ssh labuser@v111node0-adaflds023asdf-23423kjl.appnet.com` 20 | 21 | You will be asked to SSH into various nodes. These nodes are referred to as **v111node0**, **v111node1** etc. These tags correspond to the very beginning of the hostnames you will find in your welcome email. 22 | 23 | ## Prerequisites 24 | 25 | - Lists all your prerequisites 26 | 27 | ## Task #1 28 | 29 | Before we begin, we will need to: 30 | 31 | 1. Provide an overview of what will be done in this section 32 | 2. Use a bulleted list 33 | 34 | ## Task #2 35 | 36 | Before we begin, we will need to: 37 | 38 | 1. Create as many tasks as needed to break the lab into logical steps 39 | 40 | ## Wrap Up 41 | 42 | Thank you for taking the time to complete this lab! Feel free to try any of the other labs. I 43 | -------------------------------------------------------------------------------- /windows-101/images/iis.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-101/images/iis.png -------------------------------------------------------------------------------- /windows-101/images/tweet-app.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-101/images/tweet-app.png -------------------------------------------------------------------------------- /windows-101/tweet-app/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/windowsservercore 3 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 4 | 5 | RUN Add-WindowsFeature Web-Server 6 | EXPOSE 80 7 | 8 | RUN Set-WebConfigurationProperty -pspath 'MACHINE/WEBROOT/APPHOST' -filter 'system.applicationHost/log' -name 'centralLogFileMode' -value 'CentralW3C'; ` 9 | Set-WebConfigurationProperty -pspath 'MACHINE/WEBROOT/APPHOST' -filter 'system.applicationHost/log/centralW3CLogFile' -name 'truncateSize' -value 4294967295; ` 10 | Set-WebConfigurationProperty -pspath 'MACHINE/WEBROOT/APPHOST' -filter 'system.applicationHost/log/centralW3CLogFile' -name 'period' -value 'MaxSize'; ` 11 | Set-WebConfigurationProperty -pspath 'MACHINE/WEBROOT/APPHOST' -filter 'system.applicationHost/log/centralW3CLogFile' -name 'directory' -value 'c:\iislog' 12 | 13 | WORKDIR C:\ 14 | COPY start.ps1 . 15 | COPY index.html C:\inetpub\wwwroot 16 | 17 | CMD .\start.ps1 18 | 19 | HEALTHCHECK CMD powershell -command ` 20 | try { ` 21 | $response = Invoke-WebRequest http://localhost -UseBasicParsing; ` 22 | if ($response.StatusCode -eq 200) { return 0} ` 23 | else {return 1}; ` 24 | } catch { return 1 } -------------------------------------------------------------------------------- /windows-101/tweet-app/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 |

Welcome to DockerCon 2017!

31 | 32 |

33 | Good job on working through the Windows 101 hands-on-lab! Click to Tweet about your progress! 34 | 35 |

36 | 37 | 38 |

39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /windows-101/tweet-app/start.ps1: -------------------------------------------------------------------------------- 1 | 2 | Write-Output 'Starting w3svc' 3 | Start-Service W3SVC 4 | 5 | Write-Output 'Making HTTP GET call' 6 | Invoke-WebRequest http://localhost -UseBasicParsing | Out-Null 7 | 8 | Write-Output 'Flushing log file' 9 | netsh http flush logbuffer | Out-Null 10 | 11 | Write-Output 'Tailing log file' 12 | Get-Content -path 'c:\iislog\W3SVC\u_extend1.log' -Tail 1 -Wait -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/images/app-v1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/images/app-v1.png -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/images/v1-arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/images/v1-arch.png -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/images/v2-arch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/images/v2-arch.png -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Core/Env.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.Core 5 | { 6 | public class Env 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string DbConnectionString { get { return Get("DB_CONNECTION_STRING"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable); 17 | _Values[variable] = value; 18 | } 19 | return _Values[variable]; 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Core/ProductLaunch.Core.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {35BD1196-DDCB-41FA-98C5-C8116D749446} 8 | Library 9 | Properties 10 | ProductLaunch.Core 11 | ProductLaunch.Core 12 | v4.5.2 13 | 512 14 | 15 | 16 | true 17 | full 18 | false 19 | bin\Debug\ 20 | DEBUG;TRACE 21 | prompt 22 | 4 23 | 24 | 25 | pdbonly 26 | true 27 | bin\Release\ 28 | TRACE 29 | prompt 30 | 4 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 54 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Core/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Core")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Core")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("35bd1196-ddcb-41fa-98c5-c8116d749446")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.EndToEndTests/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 |
5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.EndToEndTests/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.EndToEndTests")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.EndToEndTests")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("d47cf813-de0e-4cc4-b9ed-8ee4b6f14869")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.EndToEndTests/ProspectSignUpSteps.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.VisualStudio.TestTools.UnitTesting; 2 | using OpenQA.Selenium; 3 | using OpenQA.Selenium.Firefox; 4 | using OpenQA.Selenium.Support.UI; 5 | using System; 6 | using System.Threading; 7 | using TechTalk.SpecFlow; 8 | 9 | namespace ProductLaunch.EndToEndTests 10 | { 11 | [Binding] 12 | public class ProspectSignUpSteps 13 | { 14 | private static IWebDriver _Driver; 15 | 16 | [BeforeFeature] 17 | public static void Setup() 18 | { 19 | _Driver = new FirefoxDriver(); 20 | } 21 | 22 | [AfterFeature] 23 | public static void TearDown() 24 | { 25 | _Driver.Close(); 26 | _Driver.Dispose(); 27 | } 28 | 29 | [Given(@"I browse to the Sign Up Page at ""(.*)""")] 30 | public void GivenIBrowseToTheSignUpPageAt(string host) 31 | { 32 | var url = $"http://{host}/SignUp"; 33 | _Driver.Navigate().GoToUrl(url); 34 | } 35 | 36 | [Given(@"I enter details '(.*)' '(.*)' '(.*)' '(.*)' '(.*)' '(.*)'")] 37 | public void GivenIEnterDetails(string firstName, string lastName, string emailAddress, 38 | string companyName, string country, string role) 39 | { 40 | _Driver.FindElement(By.Id("MainContent_txtFirstName")).SendKeys(firstName); 41 | _Driver.FindElement(By.Id("MainContent_txtLastName")).SendKeys(lastName); 42 | _Driver.FindElement(By.Id("MainContent_txtEmail")).SendKeys(emailAddress); 43 | _Driver.FindElement(By.Id("MainContent_txtCompanyName")).SendKeys(companyName); 44 | 45 | new SelectElement(_Driver.FindElement(By.Id("MainContent_ddlCountry"))).SelectByText(country); 46 | new SelectElement(_Driver.FindElement(By.Id("MainContent_ddlRole"))).SelectByText(role); 47 | } 48 | 49 | [When(@"I press Go")] 50 | public void WhenIPressGo() 51 | { 52 | var goButton = _Driver.FindElement(By.Id("MainContent_btnGo")); 53 | goButton.Click(); 54 | } 55 | 56 | [Then(@"I should see the Thank You page")] 57 | public void ThenIShouldSeeTheThankYouPage() 58 | { 59 | //HACK 60 | Thread.Sleep(1500); 61 | Assert.AreEqual("Ta", _Driver.Title); 62 | } 63 | } 64 | } 65 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.EndToEndTests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Entities/Country.cs: -------------------------------------------------------------------------------- 1 | namespace ProductLaunch.Entities 2 | { 3 | public class Country 4 | { 5 | public string CountryCode { get; set; } 6 | 7 | public string CountryName { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Entities/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Entities")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Entities")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("f1bbb80f-eb0c-41b6-a7a9-7994fb3fe5e8")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Entities/Prospect.cs: -------------------------------------------------------------------------------- 1 | namespace ProductLaunch.Entities 2 | { 3 | public class Prospect 4 | { 5 | public int ProspectId { get; set; } 6 | 7 | public string FirstName { get; set; } 8 | 9 | public string LastName { get; set; } 10 | 11 | public string CompanyName { get; set; } 12 | 13 | public string EmailAddress { get; set; } 14 | 15 | public Role Role { get; set; } 16 | 17 | public Country Country { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Entities/Role.cs: -------------------------------------------------------------------------------- 1 | namespace ProductLaunch.Entities 2 | { 3 | public class Role 4 | { 5 | public string RoleCode { get; set; } 6 | 7 | public string RoleName { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Config.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.MessageHandlers.IndexProspect 5 | { 6 | public class Config 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string ElasticsearchUrl { get { return Get("ELASTICSEARCH_URL"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Machine); 17 | if (string.IsNullOrEmpty(value)) 18 | { 19 | value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Process); 20 | } 21 | _Values[variable] = value; 22 | } 23 | return _Values[variable]; 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Documents/Prospect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ProductLaunch.MessageHandlers.IndexProspect.Documents 4 | { 5 | public class Prospect 6 | { 7 | public string FullName { get; set; } 8 | 9 | public string CompanyName { get; set; } 10 | 11 | public string EmailAddress { get; set; } 12 | 13 | public string RoleName { get; set; } 14 | 15 | public string CountryName { get; set; } 16 | 17 | public DateTime SignUpDate { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Indexer/Index.cs: -------------------------------------------------------------------------------- 1 | using Nest; 2 | using ProductLaunch.MessageHandlers.IndexProspect.Documents; 3 | using System; 4 | 5 | namespace ProductLaunch.MessageHandlers.IndexProspect.Indexer 6 | { 7 | public class Index 8 | { 9 | public static void Setup() 10 | { 11 | var node = new Uri(Config.ElasticsearchUrl); 12 | var settings = new ConnectionSettings(node); 13 | var client = new ElasticClient(settings); 14 | client.CreateIndex("prospects"); 15 | } 16 | 17 | public static void CreateDocument(Prospect prospect) 18 | { 19 | try 20 | { 21 | var node = new Uri(Config.ElasticsearchUrl); 22 | var client = new ElasticClient(node); 23 | client.Index(prospect, idx => idx.Index("prospects")); 24 | } 25 | catch (Exception ex) 26 | { 27 | Console.WriteLine($"Index prospect FAILED, email address: {prospect.EmailAddress}, ex: {ex}"); 28 | } 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Program.cs: -------------------------------------------------------------------------------- 1 | using NATS.Client; 2 | using ProductLaunch.MessageHandlers.IndexProspect.Indexer; 3 | using ProductLaunch.Messaging; 4 | using ProductLaunch.Messaging.Messages.Events; 5 | using System; 6 | using System.Threading; 7 | 8 | namespace ProductLaunch.MessageHandlers.IndexProspect 9 | { 10 | class Program 11 | { 12 | private static ManualResetEvent _ResetEvent = new ManualResetEvent(false); 13 | 14 | static void Main(string[] args) 15 | { 16 | Console.WriteLine($"Initializing Elasticsearch. url: {Config.ElasticsearchUrl}"); 17 | Index.Setup(); 18 | 19 | Console.WriteLine($"Connecting to message queue url: {Messaging.Config.MessageQueueUrl}"); 20 | using (var connection = MessageQueue.CreateConnection()) 21 | { 22 | var subscription = connection.SubscribeAsync(ProspectSignedUpEvent.MessageSubject); 23 | subscription.MessageHandler += IndexProspect; 24 | subscription.Start(); 25 | Console.WriteLine($"Listening on subject: {ProspectSignedUpEvent.MessageSubject}"); 26 | 27 | _ResetEvent.WaitOne(); 28 | connection.Close(); 29 | } 30 | } 31 | 32 | private static void IndexProspect(object sender, MsgHandlerEventArgs e) 33 | { 34 | Console.WriteLine($"Received message, subject: {e.Message.Subject}"); 35 | var eventMessage = MessageHelper.FromData(e.Message.Data); 36 | Console.WriteLine($"Indexing prospect, signed up at: {eventMessage.SignedUpAt}; event ID: {eventMessage.CorrelationId}"); 37 | 38 | var prospect = new Documents.Prospect 39 | { 40 | CompanyName = eventMessage.Prospect.CompanyName, 41 | CountryName = eventMessage.Prospect.Country.CountryName, 42 | EmailAddress = eventMessage.Prospect.EmailAddress, 43 | FullName = $"{eventMessage.Prospect.FirstName} {eventMessage.Prospect.LastName}", 44 | RoleName = eventMessage.Prospect.Role.RoleName, 45 | SignUpDate = eventMessage.SignedUpAt 46 | }; 47 | Index.CreateDocument(prospect); 48 | 49 | Console.WriteLine($"Prospect indexed; event ID: {eventMessage.CorrelationId}"); 50 | } 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.MessageHandlers.IndexProspect")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.MessageHandlers.IndexProspect")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("1354b5ab-c990-41ea-9f68-5f9933d83700")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/Program.cs: -------------------------------------------------------------------------------- 1 | using NATS.Client; 2 | using ProductLaunch.Messaging; 3 | using ProductLaunch.Messaging.Messages.Events; 4 | using ProductLaunch.Model; 5 | using System; 6 | using System.Linq; 7 | using System.Threading; 8 | 9 | namespace ProductLaunch.MessageHandlers.SaveProspect 10 | { 11 | class Program 12 | { 13 | private static ManualResetEvent _ResetEvent = new ManualResetEvent(false); 14 | 15 | static void Main(string[] args) 16 | { 17 | Console.WriteLine($"Connecting to message queue url: {Messaging.Config.MessageQueueUrl}"); 18 | using (var connection = MessageQueue.CreateConnection()) 19 | { 20 | var subscription = connection.SubscribeAsync(ProspectSignedUpEvent.MessageSubject); 21 | subscription.MessageHandler += SaveProspect; 22 | subscription.Start(); 23 | Console.WriteLine($"Listening on subject: {ProspectSignedUpEvent.MessageSubject}"); 24 | 25 | _ResetEvent.WaitOne(); 26 | connection.Close(); 27 | } 28 | } 29 | 30 | private static void SaveProspect(object sender, MsgHandlerEventArgs e) 31 | { 32 | Console.WriteLine($"Received message, subject: {e.Message.Subject}"); 33 | var eventMessage = MessageHelper.FromData(e.Message.Data); 34 | Console.WriteLine($"Saving new prospect, signed up at: {eventMessage.SignedUpAt}; event ID: {eventMessage.CorrelationId}"); 35 | 36 | var prospect = eventMessage.Prospect; 37 | using (var context = new ProductLaunchContext()) 38 | { 39 | //reload child objects: 40 | prospect.Country = context.Countries.Single(x => x.CountryCode == prospect.Country.CountryCode); 41 | prospect.Role = context.Roles.Single(x => x.RoleCode == prospect.Role.RoleCode); 42 | 43 | context.Prospects.Add(prospect); 44 | context.SaveChanges(); 45 | } 46 | 47 | Console.WriteLine($"Prospect saved. Prospect ID: {eventMessage.Prospect.ProspectId}; event ID: {eventMessage.CorrelationId}"); 48 | } 49 | } 50 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.MessageHandlers.SaveProspect")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.MessageHandlers.SaveProspect")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("65089c80-27f1-4744-979b-4c5a33b0cff6")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/Config.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.Messaging 5 | { 6 | public class Config 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string MessageQueueUrl { get { return Get("MESSAGE_QUEUE_URL"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Machine); 17 | if (string.IsNullOrEmpty(value)) 18 | { 19 | value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Process); 20 | } 21 | _Values[variable] = value; 22 | } 23 | return _Values[variable]; 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/MessageHelper.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using ProductLaunch.Messaging.Messages; 3 | using System.Text; 4 | 5 | namespace ProductLaunch.Messaging 6 | { 7 | public class MessageHelper 8 | { 9 | public static byte[] ToData(TMessage message) 10 | where TMessage : Message 11 | { 12 | var json = JsonConvert.SerializeObject(message); 13 | return Encoding.Unicode.GetBytes(json); 14 | } 15 | 16 | public static TMessage FromData(byte[] data) 17 | where TMessage : Message 18 | { 19 | var json = Encoding.Unicode.GetString(data); 20 | return (TMessage)JsonConvert.DeserializeObject(json); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/MessageQueue.cs: -------------------------------------------------------------------------------- 1 | using NATS.Client; 2 | using ProductLaunch.Messaging.Messages; 3 | 4 | namespace ProductLaunch.Messaging 5 | { 6 | public static class MessageQueue 7 | { 8 | 9 | public static void Publish(TMessage message) 10 | where TMessage : Message 11 | { 12 | using (var connection = CreateConnection()) 13 | { 14 | var data = MessageHelper.ToData(message); 15 | connection.Publish(message.Subject, data); 16 | } 17 | } 18 | 19 | public static IConnection CreateConnection() 20 | { 21 | return new ConnectionFactory().CreateConnection(Config.MessageQueueUrl); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/Messages/Events/ProspectSignedUpEvent.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Entities; 2 | using System; 3 | 4 | namespace ProductLaunch.Messaging.Messages.Events 5 | { 6 | public class ProspectSignedUpEvent : Message 7 | { 8 | public override string Subject { get { return MessageSubject; } } 9 | 10 | public DateTime SignedUpAt { get; set; } 11 | 12 | public Prospect Prospect { get; set; } 13 | 14 | public static string MessageSubject = "events.prospect.signedup"; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/Messages/Message.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ProductLaunch.Messaging.Messages 4 | { 5 | public abstract class Message 6 | { 7 | public string CorrelationId { get; set; } 8 | 9 | public abstract string Subject { get; } 10 | 11 | public Message() 12 | { 13 | CorrelationId = Guid.NewGuid().ToString(); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Messaging")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Messaging")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("e02eff91-8c52-4dce-8279-3fd1ee0659ef")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Messaging/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model.Tests/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model.Tests/ProductLaunchContextTest.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.VisualStudio.TestTools.UnitTesting; 3 | using ProductLaunch.Entities; 4 | 5 | namespace ProductLaunch.Model.Tests 6 | { 7 | [TestClass] 8 | public class ProductLaunchContextTest 9 | { 10 | [TestMethod] 11 | public void Insert() 12 | { 13 | using (var context = new ProductLaunchContext()) 14 | { 15 | var country = new Country 16 | { 17 | CountryCode = "GBR", 18 | CountryName = "United Kingdom" 19 | }; 20 | context.Countries.Add(country); 21 | 22 | var role = new Role 23 | { 24 | RoleCode = "DM", 25 | RoleName = "Decision Maker" 26 | }; 27 | context.Roles.Add(role); 28 | 29 | var prospect = new Prospect 30 | { 31 | FirstName = "A", 32 | LastName = "Prospect", 33 | CompanyName = "Docker, Inc.", 34 | EmailAddress = "a.prospect@docker.com", 35 | Country = country, 36 | Role = role 37 | }; 38 | context.Prospects.Add(prospect); 39 | context.SaveChanges(); 40 | } 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model.Tests/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Model.Tests")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Model.Tests")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("49fd06c3-cd52-425a-866d-831d09268cd0")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model.Tests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 |
6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model/Initializers/StaticDataInitializer.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Entities; 2 | using System.Data.Entity; 3 | 4 | namespace ProductLaunch.Model.Initializers 5 | { 6 | public class StaticDataInitializer : CreateDatabaseIfNotExists 7 | { 8 | protected override void Seed(ProductLaunchContext context) 9 | { 10 | AddRole(context, "DA", "Developer Advocate"); 11 | AddRole(context, "DM", "Decision Maker"); 12 | AddRole(context, "AC", "Architect"); 13 | AddRole(context, "EN", "Engineer"); 14 | AddRole(context, "OP", "IT Ops"); 15 | 16 | AddCountry(context, "GBR", "United Kingdom"); 17 | AddCountry(context, "USA", "United States"); 18 | AddCountry(context, "SWE", "Sweden"); 19 | 20 | context.SaveChanges(); 21 | } 22 | 23 | private void AddCountry(ProductLaunchContext context, string code, string name) 24 | { 25 | context.Countries.Add(new Country 26 | { 27 | CountryCode = code, 28 | CountryName = name 29 | }); 30 | } 31 | 32 | private void AddRole(ProductLaunchContext context, string code, string name) 33 | { 34 | context.Roles.Add(new Role 35 | { 36 | RoleCode = code, 37 | RoleName = name 38 | }); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model/ProductLaunchContext.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Entities; 2 | using System.Data.Entity; 3 | 4 | namespace ProductLaunch.Model 5 | { 6 | public class ProductLaunchContext : DbContext 7 | { 8 | public ProductLaunchContext() : base("ProductLaunchDb") { } 9 | 10 | public DbSet Countries { get; set; } 11 | 12 | public DbSet Roles { get; set; } 13 | 14 | public DbSet Prospects { get; set; } 15 | 16 | protected override void OnModelCreating(DbModelBuilder builder) 17 | { 18 | builder.Entity().HasKey(c => c.CountryCode); 19 | builder.Entity().HasKey(r => r.RoleCode); 20 | builder.Entity().HasOptional(p => p.Country); 21 | builder.Entity().HasOptional(p => p.Role); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Model")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Model")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("3afc4a48-5db6-48ff-a459-20ec21a2eb28")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Model/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/About.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="About" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="About.aspx.cs" Inherits="ProductLaunch.Web.About" %> 2 | 3 | 4 |

<%: Title %>.

5 |

Your application description page.

6 |

Use this area to provide additional information.

7 |
8 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/About.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class About : Page 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/About.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | 13 | 14 | public partial class About 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/App_Start/BundleConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Optimization; 6 | using System.Web.UI; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public class BundleConfig 11 | { 12 | // For more information on Bundling, visit http://go.microsoft.com/fwlink/?LinkID=303951 13 | public static void RegisterBundles(BundleCollection bundles) 14 | { 15 | bundles.Add(new ScriptBundle("~/bundles/WebFormsJs").Include( 16 | "~/Scripts/WebForms/WebForms.js", 17 | "~/Scripts/WebForms/WebUIValidation.js", 18 | "~/Scripts/WebForms/MenuStandards.js", 19 | "~/Scripts/WebForms/Focus.js", 20 | "~/Scripts/WebForms/GridView.js", 21 | "~/Scripts/WebForms/DetailsView.js", 22 | "~/Scripts/WebForms/TreeView.js", 23 | "~/Scripts/WebForms/WebParts.js")); 24 | 25 | // Order is very important for these files to work, they have explicit dependencies 26 | bundles.Add(new ScriptBundle("~/bundles/MsAjaxJs").Include( 27 | "~/Scripts/WebForms/MsAjax/MicrosoftAjax.js", 28 | "~/Scripts/WebForms/MsAjax/MicrosoftAjaxApplicationServices.js", 29 | "~/Scripts/WebForms/MsAjax/MicrosoftAjaxTimer.js", 30 | "~/Scripts/WebForms/MsAjax/MicrosoftAjaxWebForms.js")); 31 | 32 | // Use the Development version of Modernizr to develop with and learn from. Then, when you’re 33 | // ready for production, use the build tool at http://modernizr.com to pick only the tests you need 34 | bundles.Add(new ScriptBundle("~/bundles/modernizr").Include( 35 | "~/Scripts/modernizr-*")); 36 | 37 | ScriptManager.ScriptResourceMapping.AddDefinition( 38 | "respond", 39 | new ScriptResourceDefinition 40 | { 41 | Path = "~/Scripts/respond.min.js", 42 | DebugPath = "~/Scripts/respond.js", 43 | }); 44 | } 45 | } 46 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/App_Start/RouteConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Web; 4 | using System.Web.Routing; 5 | using Microsoft.AspNet.FriendlyUrls; 6 | 7 | namespace ProductLaunch.Web 8 | { 9 | public static class RouteConfig 10 | { 11 | public static void RegisterRoutes(RouteCollection routes) 12 | { 13 | var settings = new FriendlyUrlSettings(); 14 | settings.AutoRedirectMode = RedirectMode.Permanent; 15 | routes.EnableFriendlyUrls(settings); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ApplicationInsights.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Bundle.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Config.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.Web 5 | { 6 | public class Config 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string HomePageUrl { get { return Get("HOMEPAGE_URL"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Machine); 17 | if (string.IsNullOrEmpty(value)) 18 | { 19 | value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Process); 20 | } 21 | _Values[variable] = value; 22 | } 23 | return _Values[variable]; 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Contact.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Contact" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Contact.aspx.cs" Inherits="ProductLaunch.Web.Contact" %> 2 | 3 | 4 |

<%: Title %>.

5 |

Your contact page.

6 |
7 | One Microsoft Way
8 | Redmond, WA 98052-6399
9 | P: 10 | 425.555.0100 11 |
12 | 13 |
14 | Support: Support@example.com
15 | Marketing: Marketing@example.com 16 |
17 |
18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Contact.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class Contact : Page 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Contact.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | 13 | 14 | public partial class Contact 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Content/Site.css: -------------------------------------------------------------------------------- 1 | /* Move down content because we have a fixed navbar that is 50px tall */ 2 | body { 3 | padding-top: 50px; 4 | padding-bottom: 20px; 5 | } 6 | 7 | /* Wrapping element */ 8 | /* Set some basic padding to keep content from hitting the edges */ 9 | .body-content { 10 | padding-left: 15px; 11 | padding-right: 15px; 12 | } 13 | 14 | /* Set widths on the form inputs since otherwise they're 100% wide */ 15 | input, 16 | select, 17 | textarea { 18 | max-width: 280px; 19 | } 20 | 21 | 22 | /* Responsive: Portrait tablets and up */ 23 | @media screen and (min-width: 768px) { 24 | .jumbotron { 25 | margin-top: 20px; 26 | } 27 | 28 | .body-content { 29 | padding: 0; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Default.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="ProductLaunch.Web._Default" %> 2 | 3 | 4 | 5 |
6 |

We're launching a new product!

7 |

Our new product is going to be very, very good.

8 |
9 | 10 |
11 |
12 |

What's this all about?

13 |

14 | Lorem ipsum dolor sit amet lectus. In magna in praesent nibh lorem. Egestas ipsum luctus feugiat sit enim. Libero nec a. Praesent vestibulum quis enim.

15 |

16 | Morbi fusce placerat et pellentesque qui curabitur dictum nam. Adipiscing pede semper. Tellus at sem. Arcu nibh et. Magna luctus nibh. Eu erat aenean adipiscing vitae pretium. Pede nec laoreet. Adipiscing mauris lorem tortor nec massa distinctio pede justo. Gravida non purus nunc sit consequat imperdiet sodales nullam dolor vel.

17 |

18 | Check Out Our Other Products » 19 |

20 |
21 |
22 |

Interested?

23 |

24 | Give us your details and we'll keep you posted.

25 |

26 | It only takes 30 seconds to sign up. 27 |

28 |

29 | And we probably won't spam you very much. 30 |

31 |

32 | Sign Up » 33 |

34 |
35 |
36 | 37 |
38 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Default.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Net; 4 | using System.Web.UI; 5 | 6 | namespace ProductLaunch.Web 7 | { 8 | public partial class _Default : Page 9 | { 10 | protected void Page_Load(object sender, EventArgs e) 11 | { 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Default.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | 13 | 14 | public partial class _Default 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Global.asax: -------------------------------------------------------------------------------- 1 | <%@ Application Codebehind="Global.asax.cs" Inherits="ProductLaunch.Web.Global" Language="C#" %> 2 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Global.asax.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Model; 2 | using ProductLaunch.Model.Initializers; 3 | using System; 4 | using System.Data.Entity; 5 | using System.Web; 6 | using System.Web.Optimization; 7 | using System.Web.Routing; 8 | 9 | namespace ProductLaunch.Web 10 | { 11 | public class Global : HttpApplication 12 | { 13 | void Application_Start(object sender, EventArgs e) 14 | { 15 | // Code that runs on application startup 16 | RouteConfig.RegisterRoutes(RouteTable.Routes); 17 | BundleConfig.RegisterBundles(BundleTable.Bundles); 18 | 19 | Database.SetInitializer(new StaticDataInitializer()); 20 | SignUp.PreloadStaticDataCache(); 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Web")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Web")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("17a57cf4-a6c1-47c1-aa38-650db6d87f8f")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Revision and Build Numbers 33 | // by using the '*' as shown below: 34 | [assembly: AssemblyVersion("1.0.0.0")] 35 | [assembly: AssemblyFileVersion("1.0.0.0")] 36 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Scripts/WebForms/DetailsView.js: -------------------------------------------------------------------------------- 1 | //CdnPath=http://ajax.aspnetcdn.com/ajax/4.5.1/1/DetailsView.js 2 | function DetailsView() { 3 | this.pageIndex = null; 4 | this.dataKeys = null; 5 | this.createPropertyString = DetailsView_createPropertyString; 6 | this.setStateField = DetailsView_setStateValue; 7 | this.getHiddenFieldContents = DetailsView_getHiddenFieldContents; 8 | this.stateField = null; 9 | this.panelElement = null; 10 | this.callback = null; 11 | } 12 | function DetailsView_createPropertyString() { 13 | return createPropertyStringFromValues_DetailsView(this.pageIndex, this.dataKeys); 14 | } 15 | function DetailsView_setStateValue() { 16 | this.stateField.value = this.createPropertyString(); 17 | } 18 | function DetailsView_OnCallback (result, context) { 19 | var value = new String(result); 20 | var valsArray = value.split("|"); 21 | var innerHtml = valsArray[2]; 22 | for (var i = 3; i < valsArray.length; i++) { 23 | innerHtml += "|" + valsArray[i]; 24 | } 25 | context.panelElement.innerHTML = innerHtml; 26 | context.stateField.value = createPropertyStringFromValues_DetailsView(valsArray[0], valsArray[1]); 27 | } 28 | function DetailsView_getHiddenFieldContents(arg) { 29 | return arg + "|" + this.stateField.value; 30 | } 31 | function createPropertyStringFromValues_DetailsView(pageIndex, dataKeys) { 32 | var value = new Array(pageIndex, dataKeys); 33 | return value.join("|"); 34 | } 35 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Scripts/WebForms/GridView.js: -------------------------------------------------------------------------------- 1 | //CdnPath=http://ajax.aspnetcdn.com/ajax/4.5.1/1/GridView.js 2 | function GridView() { 3 | this.pageIndex = null; 4 | this.sortExpression = null; 5 | this.sortDirection = null; 6 | this.dataKeys = null; 7 | this.createPropertyString = GridView_createPropertyString; 8 | this.setStateField = GridView_setStateValue; 9 | this.getHiddenFieldContents = GridView_getHiddenFieldContents; 10 | this.stateField = null; 11 | this.panelElement = null; 12 | this.callback = null; 13 | } 14 | function GridView_createPropertyString() { 15 | return createPropertyStringFromValues_GridView(this.pageIndex, this.sortDirection, this.sortExpression, this.dataKeys); 16 | } 17 | function GridView_setStateValue() { 18 | this.stateField.value = this.createPropertyString(); 19 | } 20 | function GridView_OnCallback (result, context) { 21 | var value = new String(result); 22 | var valsArray = value.split("|"); 23 | var innerHtml = valsArray[4]; 24 | for (var i = 5; i < valsArray.length; i++) { 25 | innerHtml += "|" + valsArray[i]; 26 | } 27 | context.panelElement.innerHTML = innerHtml; 28 | context.stateField.value = createPropertyStringFromValues_GridView(valsArray[0], valsArray[1], valsArray[2], valsArray[3]); 29 | } 30 | function GridView_getHiddenFieldContents(arg) { 31 | return arg + "|" + this.stateField.value; 32 | } 33 | function createPropertyStringFromValues_GridView(pageIndex, sortDirection, sortExpression, dataKeys) { 34 | var value = new Array(pageIndex, sortDirection, sortExpression, dataKeys); 35 | return value.join("|"); 36 | } 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Scripts/WebForms/MSAjax/MicrosoftAjaxTimer.js: -------------------------------------------------------------------------------- 1 | //CdnPath=http://ajax.aspnetcdn.com/ajax/4.5.1/1/MicrosoftAjaxTimer.js 2 | //---------------------------------------------------------- 3 | // Copyright (C) Microsoft Corporation. All rights reserved. 4 | //---------------------------------------------------------- 5 | // MicrosoftAjaxTimer.js 6 | Type._registerScript("Timer.js",["MicrosoftAjaxComponentModel.js"]);Sys.UI._Timer=function(a){Sys.UI._Timer.initializeBase(this,[a]);this._interval=60000;this._enabled=true;this._postbackPending=false;this._raiseTickDelegate=null;this._endRequestHandlerDelegate=null;this._timer=null;this._pageRequestManager=null;this._uniqueID=null};Sys.UI._Timer.prototype={get_enabled:function(){return this._enabled},set_enabled:function(a){this._enabled=a},get_interval:function(){return this._interval},set_interval:function(a){this._interval=a},get_uniqueID:function(){return this._uniqueID},set_uniqueID:function(a){this._uniqueID=a},dispose:function(){this._stopTimer();if(this._pageRequestManager!==null)this._pageRequestManager.remove_endRequest(this._endRequestHandlerDelegate);Sys.UI._Timer.callBaseMethod(this,"dispose")},_doPostback:function(){__doPostBack(this.get_uniqueID(),"")},_handleEndRequest:function(c,b){var a=b.get_dataItems()[this.get_id()];if(a)this._update(a[0],a[1]);if(this._postbackPending===true&&this._pageRequestManager!==null&&this._pageRequestManager.get_isInAsyncPostBack()===false){this._postbackPending=false;this._doPostback()}},initialize:function(){Sys.UI._Timer.callBaseMethod(this,"initialize");this._raiseTickDelegate=Function.createDelegate(this,this._raiseTick);this._endRequestHandlerDelegate=Function.createDelegate(this,this._handleEndRequest);if(Sys.WebForms&&Sys.WebForms.PageRequestManager)this._pageRequestManager=Sys.WebForms.PageRequestManager.getInstance();if(this._pageRequestManager!==null)this._pageRequestManager.add_endRequest(this._endRequestHandlerDelegate);if(this.get_enabled())this._startTimer()},_raiseTick:function(){this._startTimer();if(this._pageRequestManager===null||!this._pageRequestManager.get_isInAsyncPostBack()){this._doPostback();this._postbackPending=false}else this._postbackPending=true},_startTimer:function(){this._timer=window.setTimeout(Function.createDelegate(this,this._raiseTick),this.get_interval())},_stopTimer:function(){if(this._timer!==null){window.clearTimeout(this._timer);this._timer=null}},_update:function(c,b){var a=!this.get_enabled(),d=this.get_interval()!==b;if(!a&&(!c||d)){this._stopTimer();a=true}this.set_enabled(c);this.set_interval(b);if(this.get_enabled()&&a)this._startTimer()}};Sys.UI._Timer.registerClass("Sys.UI._Timer",Sys.UI.Control); -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Scripts/_references.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Scripts/_references.js -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/SignUp.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Sign Up" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="SignUp.aspx.cs" Inherits="ProductLaunch.Web.SignUp" %> 2 | 3 | 4 | 5 |
6 |

Sign me up!

7 |
8 | 9 |
10 |
11 |

Just a few details

12 |
13 |
14 | 15 |
16 | 17 | 18 |
19 |
20 | 21 | 22 |
23 |
24 | 25 | 26 |
27 |
28 | 29 | 30 |
31 |
32 | 33 | 34 |
35 |
36 | 37 | 38 |
39 | 40 | 41 | 42 |
43 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Site.Master.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class SiteMaster : MasterPage 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Site.Master.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class SiteMaster { 14 | 15 | /// 16 | /// MainContent control. 17 | /// 18 | /// 19 | /// Auto-generated field. 20 | /// To modify move field declaration from designer file to code-behind file. 21 | /// 22 | protected global::System.Web.UI.WebControls.ContentPlaceHolder MainContent; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Site.Mobile.Master: -------------------------------------------------------------------------------- 1 | <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Site.Mobile.master.cs" Inherits="ProductLaunch.Web.Site_Mobile" %> 2 | <%@ Register Src="~/ViewSwitcher.ascx" TagPrefix="friendlyUrls" TagName="ViewSwitcher" %> 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |

Mobile Master Page

15 | 16 |
17 | 18 |
19 | 20 |
21 |
22 | 23 | 24 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Site.Mobile.Master.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class Site_Mobile : System.Web.UI.MasterPage 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Site.Mobile.Master.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class Site_Mobile { 14 | 15 | /// 16 | /// HeadContent control. 17 | /// 18 | /// 19 | /// Auto-generated field. 20 | /// To modify move field declaration from designer file to code-behind file. 21 | /// 22 | protected global::System.Web.UI.WebControls.ContentPlaceHolder HeadContent; 23 | 24 | /// 25 | /// form1 control. 26 | /// 27 | /// 28 | /// Auto-generated field. 29 | /// To modify move field declaration from designer file to code-behind file. 30 | /// 31 | protected global::System.Web.UI.HtmlControls.HtmlForm form1; 32 | 33 | /// 34 | /// FeaturedContent control. 35 | /// 36 | /// 37 | /// Auto-generated field. 38 | /// To modify move field declaration from designer file to code-behind file. 39 | /// 40 | protected global::System.Web.UI.WebControls.ContentPlaceHolder FeaturedContent; 41 | 42 | /// 43 | /// MainContent control. 44 | /// 45 | /// 46 | /// Auto-generated field. 47 | /// To modify move field declaration from designer file to code-behind file. 48 | /// 49 | protected global::System.Web.UI.WebControls.ContentPlaceHolder MainContent; 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ThankYou.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Ta" Language="C#" MasterPageFile="~/Site.Master" CodeBehind="ThankYou.aspx.cs" Inherits="ProductLaunch.Web.ThankYou" %> 2 | 3 | 4 | 5 |
6 |

Thank you!

7 |
8 | 9 |
10 |
11 |

Good work on signing up. We'll be in touch.

12 |
13 |
14 | 15 |
16 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ThankYou.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class ThankYou : System.Web.UI.Page 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ThankYou.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class ThankYou { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ViewSwitcher.ascx: -------------------------------------------------------------------------------- 1 | <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ViewSwitcher.ascx.cs" Inherits="ProductLaunch.Web.ViewSwitcher" %> 2 |
3 | <%: CurrentView %> view | Switch to <%: AlternateView %> 4 |
-------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ViewSwitcher.ascx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Routing; 6 | using System.Web.UI; 7 | using System.Web.UI.WebControls; 8 | using Microsoft.AspNet.FriendlyUrls.Resolvers; 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | public partial class ViewSwitcher : System.Web.UI.UserControl 13 | { 14 | protected string CurrentView { get; private set; } 15 | 16 | protected string AlternateView { get; private set; } 17 | 18 | protected string SwitchUrl { get; private set; } 19 | 20 | protected void Page_Load(object sender, EventArgs e) 21 | { 22 | // Determine current view 23 | var isMobile = WebFormsFriendlyUrlResolver.IsMobileView(new HttpContextWrapper(Context)); 24 | CurrentView = isMobile ? "Mobile" : "Desktop"; 25 | 26 | // Determine alternate view 27 | AlternateView = isMobile ? "Desktop" : "Mobile"; 28 | 29 | // Create switch URL from the route, e.g. ~/__FriendlyUrls_SwitchView/Mobile?ReturnUrl=/Page 30 | var switchViewRouteName = "AspNet.FriendlyUrls.SwitchView"; 31 | var switchViewRoute = RouteTable.Routes[switchViewRouteName]; 32 | if (switchViewRoute == null) 33 | { 34 | // Friendly URLs is not enabled or the name of the switch view route is out of sync 35 | this.Visible = false; 36 | return; 37 | } 38 | var url = GetRouteUrl(switchViewRouteName, new { view = AlternateView, __FriendlyUrls_SwitchViews = true }); 39 | url += "?ReturnUrl=" + HttpUtility.UrlEncode(Request.RawUrl); 40 | SwitchUrl = url; 41 | } 42 | } 43 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/ViewSwitcher.ascx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class ViewSwitcher { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Web.Debug.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 29 | 30 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Web.Release.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 19 | 30 | 31 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/favicon.ico -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/ProductLaunch.Web/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/ProductLaunch/build.ps1: -------------------------------------------------------------------------------- 1 | $nuGetPath = "C:\Chocolatey\bin\nuget.bat" 2 | $msBuildPath = "C:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe" 3 | 4 | cd c:\src 5 | & $nuGetPath restore .\ProductLaunch.sln 6 | & $msBuildPath .\ProductLaunch.Web\ProductLaunch.Web.csproj /p:OutputPath=c:\out\web\ProductLaunchWeb /p:DeployOnBuild=true /p:VSToolsPath=C:\MSBuild.Microsoft.VisualStudio.Web.targets.14.0.0.3\tools\VSToolsPath -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/build.ps1: -------------------------------------------------------------------------------- 1 | 2 | docker build ` 3 | -t dockersamples/modernize-aspnet-builder ` 4 | $pwd\docker\builder 5 | 6 | docker run --rm ` 7 | -v $pwd\ProductLaunch:c:\src ` 8 | -v $pwd\docker:c:\out ` 9 | dockersamples/modernize-aspnet-builder ` 10 | C:\src\build.ps1 11 | 12 | docker build ` 13 | -t dockersamples/modernize-aspnet-web:v1 ` 14 | $pwd\docker\web -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/docker/builder/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/windowsservercore:10.0.14393.693 3 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 4 | 5 | RUN Install-PackageProvider -Name chocolatey -RequiredVersion 2.8.5.130 -Force; ` 6 | Install-Package -Name microsoft-build-tools -RequiredVersion 14.0.25420.1 -Force; ` 7 | Install-Package -Name netfx-4.5.2-devpack -RequiredVersion 4.5.5165101 -Force; ` 8 | Install-Package -Name webdeploy -RequiredVersion 3.5.2 -Force 9 | 10 | RUN Install-Package -Name nuget.commandline -RequiredVersion 3.4.3 -Force; ` 11 | & C:\Chocolatey\bin\nuget install MSBuild.Microsoft.VisualStudio.Web.targets -Version 14.0.0.3 12 | 13 | ENTRYPOINT ["powershell"] -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/docker/web/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/aspnet:windowsservercore-10.0.14393.693 3 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 4 | 5 | RUN Set-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Services\Dnscache\Parameters' -Name ServerPriorityTimeLimit -Value 0 -Type DWord 6 | 7 | RUN Remove-Website -Name 'Default Web Site'; ` 8 | New-Item -Path 'C:\web-app' -Type Directory; ` 9 | New-Website -Name 'web-app' -PhysicalPath 'C:\web-app' -Port 80 -Force 10 | 11 | COPY ProductLaunchWeb/_PublishedWebsites/ProductLaunch.Web /web-app 12 | COPY Web.config /web-app/Web.config -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v1-src/docker/web/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Core/Env.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.Core 5 | { 6 | public class Env 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string DbConnectionString { get { return Get("DB_CONNECTION_STRING"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable); 17 | _Values[variable] = value; 18 | } 19 | return _Values[variable]; 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Core/ProductLaunch.Core.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | Debug 6 | AnyCPU 7 | {35BD1196-DDCB-41FA-98C5-C8116D749446} 8 | Library 9 | Properties 10 | ProductLaunch.Core 11 | ProductLaunch.Core 12 | v4.5.2 13 | 512 14 | 15 | 16 | true 17 | full 18 | false 19 | bin\Debug\ 20 | DEBUG;TRACE 21 | prompt 22 | 4 23 | 24 | 25 | pdbonly 26 | true 27 | bin\Release\ 28 | TRACE 29 | prompt 30 | 4 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 54 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Core/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Core")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Core")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("35bd1196-ddcb-41fa-98c5-c8116d749446")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.EndToEndTests/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 |
5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.EndToEndTests/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.EndToEndTests")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.EndToEndTests")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("d47cf813-de0e-4cc4-b9ed-8ee4b6f14869")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.EndToEndTests/ProspectSignUpSteps.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.VisualStudio.TestTools.UnitTesting; 2 | using OpenQA.Selenium; 3 | using OpenQA.Selenium.Firefox; 4 | using OpenQA.Selenium.Support.UI; 5 | using System; 6 | using System.Threading; 7 | using TechTalk.SpecFlow; 8 | 9 | namespace ProductLaunch.EndToEndTests 10 | { 11 | [Binding] 12 | public class ProspectSignUpSteps 13 | { 14 | private static IWebDriver _Driver; 15 | 16 | [BeforeFeature] 17 | public static void Setup() 18 | { 19 | _Driver = new FirefoxDriver(); 20 | } 21 | 22 | [AfterFeature] 23 | public static void TearDown() 24 | { 25 | _Driver.Close(); 26 | _Driver.Dispose(); 27 | } 28 | 29 | [Given(@"I browse to the Sign Up Page at ""(.*)""")] 30 | public void GivenIBrowseToTheSignUpPageAt(string host) 31 | { 32 | var url = $"http://{host}/SignUp"; 33 | _Driver.Navigate().GoToUrl(url); 34 | } 35 | 36 | [Given(@"I enter details '(.*)' '(.*)' '(.*)' '(.*)' '(.*)' '(.*)'")] 37 | public void GivenIEnterDetails(string firstName, string lastName, string emailAddress, 38 | string companyName, string country, string role) 39 | { 40 | _Driver.FindElement(By.Id("MainContent_txtFirstName")).SendKeys(firstName); 41 | _Driver.FindElement(By.Id("MainContent_txtLastName")).SendKeys(lastName); 42 | _Driver.FindElement(By.Id("MainContent_txtEmail")).SendKeys(emailAddress); 43 | _Driver.FindElement(By.Id("MainContent_txtCompanyName")).SendKeys(companyName); 44 | 45 | new SelectElement(_Driver.FindElement(By.Id("MainContent_ddlCountry"))).SelectByText(country); 46 | new SelectElement(_Driver.FindElement(By.Id("MainContent_ddlRole"))).SelectByText(role); 47 | } 48 | 49 | [When(@"I press Go")] 50 | public void WhenIPressGo() 51 | { 52 | var goButton = _Driver.FindElement(By.Id("MainContent_btnGo")); 53 | goButton.Click(); 54 | } 55 | 56 | [Then(@"I should see the Thank You page")] 57 | public void ThenIShouldSeeTheThankYouPage() 58 | { 59 | //HACK 60 | Thread.Sleep(1500); 61 | Assert.AreEqual("Ta", _Driver.Title); 62 | } 63 | } 64 | } 65 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.EndToEndTests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Entities/Country.cs: -------------------------------------------------------------------------------- 1 | namespace ProductLaunch.Entities 2 | { 3 | public class Country 4 | { 5 | public string CountryCode { get; set; } 6 | 7 | public string CountryName { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Entities/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Entities")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Entities")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("f1bbb80f-eb0c-41b6-a7a9-7994fb3fe5e8")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Entities/Prospect.cs: -------------------------------------------------------------------------------- 1 | namespace ProductLaunch.Entities 2 | { 3 | public class Prospect 4 | { 5 | public int ProspectId { get; set; } 6 | 7 | public string FirstName { get; set; } 8 | 9 | public string LastName { get; set; } 10 | 11 | public string CompanyName { get; set; } 12 | 13 | public string EmailAddress { get; set; } 14 | 15 | public Role Role { get; set; } 16 | 17 | public Country Country { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Entities/Role.cs: -------------------------------------------------------------------------------- 1 | namespace ProductLaunch.Entities 2 | { 3 | public class Role 4 | { 5 | public string RoleCode { get; set; } 6 | 7 | public string RoleName { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Config.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.MessageHandlers.IndexProspect 5 | { 6 | public class Config 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string ElasticsearchUrl { get { return Get("ELASTICSEARCH_URL"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Machine); 17 | if (string.IsNullOrEmpty(value)) 18 | { 19 | value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Process); 20 | } 21 | _Values[variable] = value; 22 | } 23 | return _Values[variable]; 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Documents/Prospect.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ProductLaunch.MessageHandlers.IndexProspect.Documents 4 | { 5 | public class Prospect 6 | { 7 | public string FullName { get; set; } 8 | 9 | public string CompanyName { get; set; } 10 | 11 | public string EmailAddress { get; set; } 12 | 13 | public string RoleName { get; set; } 14 | 15 | public string CountryName { get; set; } 16 | 17 | public DateTime SignUpDate { get; set; } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Indexer/Index.cs: -------------------------------------------------------------------------------- 1 | using Nest; 2 | using ProductLaunch.MessageHandlers.IndexProspect.Documents; 3 | using System; 4 | 5 | namespace ProductLaunch.MessageHandlers.IndexProspect.Indexer 6 | { 7 | public class Index 8 | { 9 | public static void Setup() 10 | { 11 | var node = new Uri(Config.ElasticsearchUrl); 12 | var settings = new ConnectionSettings(node); 13 | var client = new ElasticClient(settings); 14 | client.CreateIndex("prospects"); 15 | } 16 | 17 | public static void CreateDocument(Prospect prospect) 18 | { 19 | try 20 | { 21 | var node = new Uri(Config.ElasticsearchUrl); 22 | var client = new ElasticClient(node); 23 | client.Index(prospect, idx => idx.Index("prospects")); 24 | } 25 | catch (Exception ex) 26 | { 27 | Console.WriteLine($"Index prospect FAILED, email address: {prospect.EmailAddress}, ex: {ex}"); 28 | } 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Program.cs: -------------------------------------------------------------------------------- 1 | using NATS.Client; 2 | using ProductLaunch.MessageHandlers.IndexProspect.Indexer; 3 | using ProductLaunch.Messaging; 4 | using ProductLaunch.Messaging.Messages.Events; 5 | using System; 6 | using System.Threading; 7 | 8 | namespace ProductLaunch.MessageHandlers.IndexProspect 9 | { 10 | class Program 11 | { 12 | private static ManualResetEvent _ResetEvent = new ManualResetEvent(false); 13 | 14 | static void Main(string[] args) 15 | { 16 | Console.WriteLine($"Initializing Elasticsearch. url: {Config.ElasticsearchUrl}"); 17 | Index.Setup(); 18 | 19 | Console.WriteLine($"Connecting to message queue url: {Messaging.Config.MessageQueueUrl}"); 20 | using (var connection = MessageQueue.CreateConnection()) 21 | { 22 | var subscription = connection.SubscribeAsync(ProspectSignedUpEvent.MessageSubject); 23 | subscription.MessageHandler += IndexProspect; 24 | subscription.Start(); 25 | Console.WriteLine($"Listening on subject: {ProspectSignedUpEvent.MessageSubject}"); 26 | 27 | _ResetEvent.WaitOne(); 28 | connection.Close(); 29 | } 30 | } 31 | 32 | private static void IndexProspect(object sender, MsgHandlerEventArgs e) 33 | { 34 | Console.WriteLine($"Received message, subject: {e.Message.Subject}"); 35 | var eventMessage = MessageHelper.FromData(e.Message.Data); 36 | Console.WriteLine($"Indexing prospect, signed up at: {eventMessage.SignedUpAt}; event ID: {eventMessage.CorrelationId}"); 37 | 38 | var prospect = new Documents.Prospect 39 | { 40 | CompanyName = eventMessage.Prospect.CompanyName, 41 | CountryName = eventMessage.Prospect.Country.CountryName, 42 | EmailAddress = eventMessage.Prospect.EmailAddress, 43 | FullName = $"{eventMessage.Prospect.FirstName} {eventMessage.Prospect.LastName}", 44 | RoleName = eventMessage.Prospect.Role.RoleName, 45 | SignUpDate = eventMessage.SignedUpAt 46 | }; 47 | Index.CreateDocument(prospect); 48 | 49 | Console.WriteLine($"Prospect indexed; event ID: {eventMessage.CorrelationId}"); 50 | } 51 | } 52 | } 53 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.MessageHandlers.IndexProspect")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.MessageHandlers.IndexProspect")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("1354b5ab-c990-41ea-9f68-5f9933d83700")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.IndexProspect/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/Program.cs: -------------------------------------------------------------------------------- 1 | using NATS.Client; 2 | using ProductLaunch.Messaging; 3 | using ProductLaunch.Messaging.Messages.Events; 4 | using ProductLaunch.Model; 5 | using System; 6 | using System.Linq; 7 | using System.Threading; 8 | 9 | namespace ProductLaunch.MessageHandlers.SaveProspect 10 | { 11 | class Program 12 | { 13 | private static ManualResetEvent _ResetEvent = new ManualResetEvent(false); 14 | 15 | static void Main(string[] args) 16 | { 17 | Console.WriteLine($"Connecting to message queue url: {Messaging.Config.MessageQueueUrl}"); 18 | using (var connection = MessageQueue.CreateConnection()) 19 | { 20 | var subscription = connection.SubscribeAsync(ProspectSignedUpEvent.MessageSubject); 21 | subscription.MessageHandler += SaveProspect; 22 | subscription.Start(); 23 | Console.WriteLine($"Listening on subject: {ProspectSignedUpEvent.MessageSubject}"); 24 | 25 | _ResetEvent.WaitOne(); 26 | connection.Close(); 27 | } 28 | } 29 | 30 | private static void SaveProspect(object sender, MsgHandlerEventArgs e) 31 | { 32 | Console.WriteLine($"Received message, subject: {e.Message.Subject}"); 33 | var eventMessage = MessageHelper.FromData(e.Message.Data); 34 | Console.WriteLine($"Saving new prospect, signed up at: {eventMessage.SignedUpAt}; event ID: {eventMessage.CorrelationId}"); 35 | 36 | var prospect = eventMessage.Prospect; 37 | using (var context = new ProductLaunchContext()) 38 | { 39 | //reload child objects: 40 | prospect.Country = context.Countries.Single(x => x.CountryCode == prospect.Country.CountryCode); 41 | prospect.Role = context.Roles.Single(x => x.RoleCode == prospect.Role.RoleCode); 42 | 43 | context.Prospects.Add(prospect); 44 | context.SaveChanges(); 45 | } 46 | 47 | Console.WriteLine($"Prospect saved. Prospect ID: {eventMessage.Prospect.ProspectId}; event ID: {eventMessage.CorrelationId}"); 48 | } 49 | } 50 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.MessageHandlers.SaveProspect")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.MessageHandlers.SaveProspect")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("65089c80-27f1-4744-979b-4c5a33b0cff6")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.MessageHandlers.SaveProspect/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/Config.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.Messaging 5 | { 6 | public class Config 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string MessageQueueUrl { get { return Get("MESSAGE_QUEUE_URL"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Machine); 17 | if (string.IsNullOrEmpty(value)) 18 | { 19 | value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Process); 20 | } 21 | _Values[variable] = value; 22 | } 23 | return _Values[variable]; 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/MessageHelper.cs: -------------------------------------------------------------------------------- 1 | using Newtonsoft.Json; 2 | using ProductLaunch.Messaging.Messages; 3 | using System.Text; 4 | 5 | namespace ProductLaunch.Messaging 6 | { 7 | public class MessageHelper 8 | { 9 | public static byte[] ToData(TMessage message) 10 | where TMessage : Message 11 | { 12 | var json = JsonConvert.SerializeObject(message); 13 | return Encoding.Unicode.GetBytes(json); 14 | } 15 | 16 | public static TMessage FromData(byte[] data) 17 | where TMessage : Message 18 | { 19 | var json = Encoding.Unicode.GetString(data); 20 | return (TMessage)JsonConvert.DeserializeObject(json); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/MessageQueue.cs: -------------------------------------------------------------------------------- 1 | using NATS.Client; 2 | using ProductLaunch.Messaging.Messages; 3 | 4 | namespace ProductLaunch.Messaging 5 | { 6 | public static class MessageQueue 7 | { 8 | 9 | public static void Publish(TMessage message) 10 | where TMessage : Message 11 | { 12 | using (var connection = CreateConnection()) 13 | { 14 | var data = MessageHelper.ToData(message); 15 | connection.Publish(message.Subject, data); 16 | } 17 | } 18 | 19 | public static IConnection CreateConnection() 20 | { 21 | return new ConnectionFactory().CreateConnection(Config.MessageQueueUrl); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/Messages/Events/ProspectSignedUpEvent.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Entities; 2 | using System; 3 | 4 | namespace ProductLaunch.Messaging.Messages.Events 5 | { 6 | public class ProspectSignedUpEvent : Message 7 | { 8 | public override string Subject { get { return MessageSubject; } } 9 | 10 | public DateTime SignedUpAt { get; set; } 11 | 12 | public Prospect Prospect { get; set; } 13 | 14 | public static string MessageSubject = "events.prospect.signedup"; 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/Messages/Message.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace ProductLaunch.Messaging.Messages 4 | { 5 | public abstract class Message 6 | { 7 | public string CorrelationId { get; set; } 8 | 9 | public abstract string Subject { get; } 10 | 11 | public Message() 12 | { 13 | CorrelationId = Guid.NewGuid().ToString(); 14 | } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Messaging")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Messaging")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("e02eff91-8c52-4dce-8279-3fd1ee0659ef")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Messaging/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model.Tests/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model.Tests/ProductLaunchContextTest.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using Microsoft.VisualStudio.TestTools.UnitTesting; 3 | using ProductLaunch.Entities; 4 | 5 | namespace ProductLaunch.Model.Tests 6 | { 7 | [TestClass] 8 | public class ProductLaunchContextTest 9 | { 10 | [TestMethod] 11 | public void Insert() 12 | { 13 | using (var context = new ProductLaunchContext()) 14 | { 15 | var country = new Country 16 | { 17 | CountryCode = "GBR", 18 | CountryName = "United Kingdom" 19 | }; 20 | context.Countries.Add(country); 21 | 22 | var role = new Role 23 | { 24 | RoleCode = "DM", 25 | RoleName = "Decision Maker" 26 | }; 27 | context.Roles.Add(role); 28 | 29 | var prospect = new Prospect 30 | { 31 | FirstName = "A", 32 | LastName = "Prospect", 33 | CompanyName = "Docker, Inc.", 34 | EmailAddress = "a.prospect@docker.com", 35 | Country = country, 36 | Role = role 37 | }; 38 | context.Prospects.Add(prospect); 39 | context.SaveChanges(); 40 | } 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model.Tests/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Model.Tests")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Model.Tests")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("49fd06c3-cd52-425a-866d-831d09268cd0")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model.Tests/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model/App.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 |
6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model/Config.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | 4 | namespace ProductLaunch.Model 5 | { 6 | public class Config 7 | { 8 | private static Dictionary _Values = new Dictionary(); 9 | 10 | public static string DbConnectionString { get { return Get("DB_CONNECTION_STRING"); } } 11 | 12 | private static string Get(string variable) 13 | { 14 | if (!_Values.ContainsKey(variable)) 15 | { 16 | var value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Machine); 17 | if (string.IsNullOrEmpty(value)) 18 | { 19 | value = Environment.GetEnvironmentVariable(variable, EnvironmentVariableTarget.Process); 20 | } 21 | _Values[variable] = value; 22 | } 23 | return _Values[variable]; 24 | } 25 | } 26 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model/Initializers/StaticDataInitializer.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Entities; 2 | using System.Data.Entity; 3 | 4 | namespace ProductLaunch.Model.Initializers 5 | { 6 | public class StaticDataInitializer : CreateDatabaseIfNotExists 7 | { 8 | protected override void Seed(ProductLaunchContext context) 9 | { 10 | AddRole(context, "DA", "Developer Advocate"); 11 | AddRole(context, "DM", "Decision Maker"); 12 | AddRole(context, "AC", "Architect"); 13 | AddRole(context, "EN", "Engineer"); 14 | AddRole(context, "OP", "IT Ops"); 15 | 16 | AddCountry(context, "GBR", "United Kingdom"); 17 | AddCountry(context, "USA", "United States"); 18 | AddCountry(context, "SWE", "Sweden"); 19 | 20 | context.SaveChanges(); 21 | } 22 | 23 | private void AddCountry(ProductLaunchContext context, string code, string name) 24 | { 25 | context.Countries.Add(new Country 26 | { 27 | CountryCode = code, 28 | CountryName = name 29 | }); 30 | } 31 | 32 | private void AddRole(ProductLaunchContext context, string code, string name) 33 | { 34 | context.Roles.Add(new Role 35 | { 36 | RoleCode = code, 37 | RoleName = name 38 | }); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model/ProductLaunchContext.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Entities; 2 | using System.Data.Entity; 3 | 4 | namespace ProductLaunch.Model 5 | { 6 | public class ProductLaunchContext : DbContext 7 | { 8 | public ProductLaunchContext() : base(Config.DbConnectionString) { } 9 | 10 | public DbSet Countries { get; set; } 11 | 12 | public DbSet Roles { get; set; } 13 | 14 | public DbSet Prospects { get; set; } 15 | 16 | protected override void OnModelCreating(DbModelBuilder builder) 17 | { 18 | builder.Entity().HasKey(c => c.CountryCode); 19 | builder.Entity().HasKey(r => r.RoleCode); 20 | builder.Entity().HasOptional(p => p.Country); 21 | builder.Entity().HasOptional(p => p.Role); 22 | } 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Model")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Model")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("3afc4a48-5db6-48ff-a459-20ec21a2eb28")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Build and Revision Numbers 33 | // by using the '*' as shown below: 34 | // [assembly: AssemblyVersion("1.0.*")] 35 | [assembly: AssemblyVersion("1.0.0.0")] 36 | [assembly: AssemblyFileVersion("1.0.0.0")] 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Model/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/About.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="About" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="About.aspx.cs" Inherits="ProductLaunch.Web.About" %> 2 | 3 | 4 |

<%: Title %>.

5 |

Your application description page.

6 |

Use this area to provide additional information.

7 |
8 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/About.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class About : Page 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/About.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | 13 | 14 | public partial class About 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/App_Start/BundleConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Optimization; 6 | using System.Web.UI; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public class BundleConfig 11 | { 12 | // For more information on Bundling, visit http://go.microsoft.com/fwlink/?LinkID=303951 13 | public static void RegisterBundles(BundleCollection bundles) 14 | { 15 | bundles.Add(new ScriptBundle("~/bundles/WebFormsJs").Include( 16 | "~/Scripts/WebForms/WebForms.js", 17 | "~/Scripts/WebForms/WebUIValidation.js", 18 | "~/Scripts/WebForms/MenuStandards.js", 19 | "~/Scripts/WebForms/Focus.js", 20 | "~/Scripts/WebForms/GridView.js", 21 | "~/Scripts/WebForms/DetailsView.js", 22 | "~/Scripts/WebForms/TreeView.js", 23 | "~/Scripts/WebForms/WebParts.js")); 24 | 25 | // Order is very important for these files to work, they have explicit dependencies 26 | bundles.Add(new ScriptBundle("~/bundles/MsAjaxJs").Include( 27 | "~/Scripts/WebForms/MsAjax/MicrosoftAjax.js", 28 | "~/Scripts/WebForms/MsAjax/MicrosoftAjaxApplicationServices.js", 29 | "~/Scripts/WebForms/MsAjax/MicrosoftAjaxTimer.js", 30 | "~/Scripts/WebForms/MsAjax/MicrosoftAjaxWebForms.js")); 31 | 32 | // Use the Development version of Modernizr to develop with and learn from. Then, when you’re 33 | // ready for production, use the build tool at http://modernizr.com to pick only the tests you need 34 | bundles.Add(new ScriptBundle("~/bundles/modernizr").Include( 35 | "~/Scripts/modernizr-*")); 36 | 37 | ScriptManager.ScriptResourceMapping.AddDefinition( 38 | "respond", 39 | new ScriptResourceDefinition 40 | { 41 | Path = "~/Scripts/respond.min.js", 42 | DebugPath = "~/Scripts/respond.js", 43 | }); 44 | } 45 | } 46 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/App_Start/RouteConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Web; 4 | using System.Web.Routing; 5 | using Microsoft.AspNet.FriendlyUrls; 6 | 7 | namespace ProductLaunch.Web 8 | { 9 | public static class RouteConfig 10 | { 11 | public static void RegisterRoutes(RouteCollection routes) 12 | { 13 | var settings = new FriendlyUrlSettings(); 14 | settings.AutoRedirectMode = RedirectMode.Permanent; 15 | routes.EnableFriendlyUrls(settings); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ApplicationInsights.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Bundle.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Contact.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Contact" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Contact.aspx.cs" Inherits="ProductLaunch.Web.Contact" %> 2 | 3 | 4 |

<%: Title %>.

5 |

Your contact page.

6 |
7 | One Microsoft Way
8 | Redmond, WA 98052-6399
9 | P: 10 | 425.555.0100 11 |
12 | 13 |
14 | Support: Support@example.com
15 | Marketing: Marketing@example.com 16 |
17 |
18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Contact.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class Contact : Page 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Contact.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | 13 | 14 | public partial class Contact 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Content/Site.css: -------------------------------------------------------------------------------- 1 | /* Move down content because we have a fixed navbar that is 50px tall */ 2 | body { 3 | padding-top: 50px; 4 | padding-bottom: 20px; 5 | } 6 | 7 | /* Wrapping element */ 8 | /* Set some basic padding to keep content from hitting the edges */ 9 | .body-content { 10 | padding-left: 15px; 11 | padding-right: 15px; 12 | } 13 | 14 | /* Set widths on the form inputs since otherwise they're 100% wide */ 15 | input, 16 | select, 17 | textarea { 18 | max-width: 280px; 19 | } 20 | 21 | 22 | /* Responsive: Portrait tablets and up */ 23 | @media screen and (min-width: 768px) { 24 | .jumbotron { 25 | margin-top: 20px; 26 | } 27 | 28 | .body-content { 29 | padding: 0; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Default.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="ProductLaunch.Web._Default" %> 2 | 3 | 4 | 5 |
6 |

We're launching a new product!

7 |

Our new product is going to be very, very good.

8 |
9 | 10 |
11 |
12 |

What's this all about?

13 |

14 | Lorem ipsum dolor sit amet lectus. In magna in praesent nibh lorem. Egestas ipsum luctus feugiat sit enim. Libero nec a. Praesent vestibulum quis enim.

15 |

16 | Morbi fusce placerat et pellentesque qui curabitur dictum nam. Adipiscing pede semper. Tellus at sem. Arcu nibh et. Magna luctus nibh. Eu erat aenean adipiscing vitae pretium. Pede nec laoreet. Adipiscing mauris lorem tortor nec massa distinctio pede justo. Gravida non purus nunc sit consequat imperdiet sodales nullam dolor vel.

17 |

18 | Check Out Our Other Products » 19 |

20 |
21 |
22 |

Interested?

23 |

24 | Give us your details and we'll keep you posted.

25 |

26 | It only takes 30 seconds to sign up. 27 |

28 |

29 | And we probably won't spam you very much. 30 |

31 |

32 | Sign Up » 33 |

34 |
35 |
36 | 37 |
38 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Default.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.IO; 3 | using System.Net; 4 | using System.Web.UI; 5 | 6 | namespace ProductLaunch.Web 7 | { 8 | public partial class _Default : Page 9 | { 10 | protected void Page_Load(object sender, EventArgs e) 11 | { 12 | } 13 | } 14 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Default.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | 13 | 14 | public partial class _Default 15 | { 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Global.asax: -------------------------------------------------------------------------------- 1 | <%@ Application Codebehind="Global.asax.cs" Inherits="ProductLaunch.Web.Global" Language="C#" %> 2 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Global.asax.cs: -------------------------------------------------------------------------------- 1 | using ProductLaunch.Model; 2 | using ProductLaunch.Model.Initializers; 3 | using System; 4 | using System.Data.Entity; 5 | using System.Web; 6 | using System.Web.Optimization; 7 | using System.Web.Routing; 8 | 9 | namespace ProductLaunch.Web 10 | { 11 | public class Global : HttpApplication 12 | { 13 | void Application_Start(object sender, EventArgs e) 14 | { 15 | // Code that runs on application startup 16 | RouteConfig.RegisterRoutes(RouteTable.Routes); 17 | BundleConfig.RegisterBundles(BundleTable.Bundles); 18 | 19 | Database.SetInitializer(new StaticDataInitializer()); 20 | SignUp.PreloadStaticDataCache(); 21 | } 22 | } 23 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("ProductLaunch.Web")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("")] 12 | [assembly: AssemblyProduct("ProductLaunch.Web")] 13 | [assembly: AssemblyCopyright("Copyright © 2017")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("17a57cf4-a6c1-47c1-aa38-650db6d87f8f")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Revision and Build Numbers 33 | // by using the '*' as shown below: 34 | [assembly: AssemblyVersion("1.0.0.0")] 35 | [assembly: AssemblyFileVersion("1.0.0.0")] 36 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Scripts/WebForms/DetailsView.js: -------------------------------------------------------------------------------- 1 | //CdnPath=http://ajax.aspnetcdn.com/ajax/4.5.1/1/DetailsView.js 2 | function DetailsView() { 3 | this.pageIndex = null; 4 | this.dataKeys = null; 5 | this.createPropertyString = DetailsView_createPropertyString; 6 | this.setStateField = DetailsView_setStateValue; 7 | this.getHiddenFieldContents = DetailsView_getHiddenFieldContents; 8 | this.stateField = null; 9 | this.panelElement = null; 10 | this.callback = null; 11 | } 12 | function DetailsView_createPropertyString() { 13 | return createPropertyStringFromValues_DetailsView(this.pageIndex, this.dataKeys); 14 | } 15 | function DetailsView_setStateValue() { 16 | this.stateField.value = this.createPropertyString(); 17 | } 18 | function DetailsView_OnCallback (result, context) { 19 | var value = new String(result); 20 | var valsArray = value.split("|"); 21 | var innerHtml = valsArray[2]; 22 | for (var i = 3; i < valsArray.length; i++) { 23 | innerHtml += "|" + valsArray[i]; 24 | } 25 | context.panelElement.innerHTML = innerHtml; 26 | context.stateField.value = createPropertyStringFromValues_DetailsView(valsArray[0], valsArray[1]); 27 | } 28 | function DetailsView_getHiddenFieldContents(arg) { 29 | return arg + "|" + this.stateField.value; 30 | } 31 | function createPropertyStringFromValues_DetailsView(pageIndex, dataKeys) { 32 | var value = new Array(pageIndex, dataKeys); 33 | return value.join("|"); 34 | } 35 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Scripts/WebForms/GridView.js: -------------------------------------------------------------------------------- 1 | //CdnPath=http://ajax.aspnetcdn.com/ajax/4.5.1/1/GridView.js 2 | function GridView() { 3 | this.pageIndex = null; 4 | this.sortExpression = null; 5 | this.sortDirection = null; 6 | this.dataKeys = null; 7 | this.createPropertyString = GridView_createPropertyString; 8 | this.setStateField = GridView_setStateValue; 9 | this.getHiddenFieldContents = GridView_getHiddenFieldContents; 10 | this.stateField = null; 11 | this.panelElement = null; 12 | this.callback = null; 13 | } 14 | function GridView_createPropertyString() { 15 | return createPropertyStringFromValues_GridView(this.pageIndex, this.sortDirection, this.sortExpression, this.dataKeys); 16 | } 17 | function GridView_setStateValue() { 18 | this.stateField.value = this.createPropertyString(); 19 | } 20 | function GridView_OnCallback (result, context) { 21 | var value = new String(result); 22 | var valsArray = value.split("|"); 23 | var innerHtml = valsArray[4]; 24 | for (var i = 5; i < valsArray.length; i++) { 25 | innerHtml += "|" + valsArray[i]; 26 | } 27 | context.panelElement.innerHTML = innerHtml; 28 | context.stateField.value = createPropertyStringFromValues_GridView(valsArray[0], valsArray[1], valsArray[2], valsArray[3]); 29 | } 30 | function GridView_getHiddenFieldContents(arg) { 31 | return arg + "|" + this.stateField.value; 32 | } 33 | function createPropertyStringFromValues_GridView(pageIndex, sortDirection, sortExpression, dataKeys) { 34 | var value = new Array(pageIndex, sortDirection, sortExpression, dataKeys); 35 | return value.join("|"); 36 | } 37 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Scripts/WebForms/MSAjax/MicrosoftAjaxTimer.js: -------------------------------------------------------------------------------- 1 | //CdnPath=http://ajax.aspnetcdn.com/ajax/4.5.1/1/MicrosoftAjaxTimer.js 2 | //---------------------------------------------------------- 3 | // Copyright (C) Microsoft Corporation. All rights reserved. 4 | //---------------------------------------------------------- 5 | // MicrosoftAjaxTimer.js 6 | Type._registerScript("Timer.js",["MicrosoftAjaxComponentModel.js"]);Sys.UI._Timer=function(a){Sys.UI._Timer.initializeBase(this,[a]);this._interval=60000;this._enabled=true;this._postbackPending=false;this._raiseTickDelegate=null;this._endRequestHandlerDelegate=null;this._timer=null;this._pageRequestManager=null;this._uniqueID=null};Sys.UI._Timer.prototype={get_enabled:function(){return this._enabled},set_enabled:function(a){this._enabled=a},get_interval:function(){return this._interval},set_interval:function(a){this._interval=a},get_uniqueID:function(){return this._uniqueID},set_uniqueID:function(a){this._uniqueID=a},dispose:function(){this._stopTimer();if(this._pageRequestManager!==null)this._pageRequestManager.remove_endRequest(this._endRequestHandlerDelegate);Sys.UI._Timer.callBaseMethod(this,"dispose")},_doPostback:function(){__doPostBack(this.get_uniqueID(),"")},_handleEndRequest:function(c,b){var a=b.get_dataItems()[this.get_id()];if(a)this._update(a[0],a[1]);if(this._postbackPending===true&&this._pageRequestManager!==null&&this._pageRequestManager.get_isInAsyncPostBack()===false){this._postbackPending=false;this._doPostback()}},initialize:function(){Sys.UI._Timer.callBaseMethod(this,"initialize");this._raiseTickDelegate=Function.createDelegate(this,this._raiseTick);this._endRequestHandlerDelegate=Function.createDelegate(this,this._handleEndRequest);if(Sys.WebForms&&Sys.WebForms.PageRequestManager)this._pageRequestManager=Sys.WebForms.PageRequestManager.getInstance();if(this._pageRequestManager!==null)this._pageRequestManager.add_endRequest(this._endRequestHandlerDelegate);if(this.get_enabled())this._startTimer()},_raiseTick:function(){this._startTimer();if(this._pageRequestManager===null||!this._pageRequestManager.get_isInAsyncPostBack()){this._doPostback();this._postbackPending=false}else this._postbackPending=true},_startTimer:function(){this._timer=window.setTimeout(Function.createDelegate(this,this._raiseTick),this.get_interval())},_stopTimer:function(){if(this._timer!==null){window.clearTimeout(this._timer);this._timer=null}},_update:function(c,b){var a=!this.get_enabled(),d=this.get_interval()!==b;if(!a&&(!c||d)){this._stopTimer();a=true}this.set_enabled(c);this.set_interval(b);if(this.get_enabled()&&a)this._startTimer()}};Sys.UI._Timer.registerClass("Sys.UI._Timer",Sys.UI.Control); -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Scripts/_references.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Scripts/_references.js -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/SignUp.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Sign Up" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="SignUp.aspx.cs" Inherits="ProductLaunch.Web.SignUp" %> 2 | 3 | 4 | 5 |
6 |

Sign me up!

7 |
8 | 9 |
10 |
11 |

Just a few details

12 |
13 |
14 | 15 |
16 | 17 | 18 |
19 |
20 | 21 | 22 |
23 |
24 | 25 | 26 |
27 |
28 | 29 | 30 |
31 |
32 | 33 | 34 |
35 |
36 | 37 | 38 |
39 | 40 | 41 | 42 |
43 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Site.Master.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class SiteMaster : MasterPage 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Site.Master.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class SiteMaster { 14 | 15 | /// 16 | /// MainContent control. 17 | /// 18 | /// 19 | /// Auto-generated field. 20 | /// To modify move field declaration from designer file to code-behind file. 21 | /// 22 | protected global::System.Web.UI.WebControls.ContentPlaceHolder MainContent; 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Site.Mobile.Master: -------------------------------------------------------------------------------- 1 | <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Site.Mobile.master.cs" Inherits="ProductLaunch.Web.Site_Mobile" %> 2 | <%@ Register Src="~/ViewSwitcher.ascx" TagPrefix="friendlyUrls" TagName="ViewSwitcher" %> 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 |
14 |

Mobile Master Page

15 | 16 |
17 | 18 |
19 | 20 |
21 |
22 | 23 | 24 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Site.Mobile.Master.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class Site_Mobile : System.Web.UI.MasterPage 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Site.Mobile.Master.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class Site_Mobile { 14 | 15 | /// 16 | /// HeadContent control. 17 | /// 18 | /// 19 | /// Auto-generated field. 20 | /// To modify move field declaration from designer file to code-behind file. 21 | /// 22 | protected global::System.Web.UI.WebControls.ContentPlaceHolder HeadContent; 23 | 24 | /// 25 | /// form1 control. 26 | /// 27 | /// 28 | /// Auto-generated field. 29 | /// To modify move field declaration from designer file to code-behind file. 30 | /// 31 | protected global::System.Web.UI.HtmlControls.HtmlForm form1; 32 | 33 | /// 34 | /// FeaturedContent control. 35 | /// 36 | /// 37 | /// Auto-generated field. 38 | /// To modify move field declaration from designer file to code-behind file. 39 | /// 40 | protected global::System.Web.UI.WebControls.ContentPlaceHolder FeaturedContent; 41 | 42 | /// 43 | /// MainContent control. 44 | /// 45 | /// 46 | /// Auto-generated field. 47 | /// To modify move field declaration from designer file to code-behind file. 48 | /// 49 | protected global::System.Web.UI.WebControls.ContentPlaceHolder MainContent; 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ThankYou.aspx: -------------------------------------------------------------------------------- 1 | <%@ Page Title="Ta" Language="C#" MasterPageFile="~/Site.Master" CodeBehind="ThankYou.aspx.cs" Inherits="ProductLaunch.Web.ThankYou" %> 2 | 3 | 4 | 5 |
6 |

Thank you!

7 |
8 | 9 |
10 |
11 |

Good work on signing up. We'll be in touch.

12 |
13 |
14 | 15 |
16 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ThankYou.aspx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.UI; 6 | using System.Web.UI.WebControls; 7 | 8 | namespace ProductLaunch.Web 9 | { 10 | public partial class ThankYou : System.Web.UI.Page 11 | { 12 | protected void Page_Load(object sender, EventArgs e) 13 | { 14 | 15 | } 16 | } 17 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ThankYou.aspx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class ThankYou { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ViewSwitcher.ascx: -------------------------------------------------------------------------------- 1 | <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="ViewSwitcher.ascx.cs" Inherits="ProductLaunch.Web.ViewSwitcher" %> 2 |
3 | <%: CurrentView %> view | Switch to <%: AlternateView %> 4 |
-------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ViewSwitcher.ascx.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Routing; 6 | using System.Web.UI; 7 | using System.Web.UI.WebControls; 8 | using Microsoft.AspNet.FriendlyUrls.Resolvers; 9 | 10 | namespace ProductLaunch.Web 11 | { 12 | public partial class ViewSwitcher : System.Web.UI.UserControl 13 | { 14 | protected string CurrentView { get; private set; } 15 | 16 | protected string AlternateView { get; private set; } 17 | 18 | protected string SwitchUrl { get; private set; } 19 | 20 | protected void Page_Load(object sender, EventArgs e) 21 | { 22 | // Determine current view 23 | var isMobile = WebFormsFriendlyUrlResolver.IsMobileView(new HttpContextWrapper(Context)); 24 | CurrentView = isMobile ? "Mobile" : "Desktop"; 25 | 26 | // Determine alternate view 27 | AlternateView = isMobile ? "Desktop" : "Mobile"; 28 | 29 | // Create switch URL from the route, e.g. ~/__FriendlyUrls_SwitchView/Mobile?ReturnUrl=/Page 30 | var switchViewRouteName = "AspNet.FriendlyUrls.SwitchView"; 31 | var switchViewRoute = RouteTable.Routes[switchViewRouteName]; 32 | if (switchViewRoute == null) 33 | { 34 | // Friendly URLs is not enabled or the name of the switch view route is out of sync 35 | this.Visible = false; 36 | return; 37 | } 38 | var url = GetRouteUrl(switchViewRouteName, new { view = AlternateView, __FriendlyUrls_SwitchViews = true }); 39 | url += "?ReturnUrl=" + HttpUtility.UrlEncode(Request.RawUrl); 40 | SwitchUrl = url; 41 | } 42 | } 43 | } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/ViewSwitcher.ascx.designer.cs: -------------------------------------------------------------------------------- 1 | //------------------------------------------------------------------------------ 2 | // 3 | // This code was generated by a tool. 4 | // 5 | // Changes to this file may cause incorrect behavior and will be lost if 6 | // the code is regenerated. 7 | // 8 | //------------------------------------------------------------------------------ 9 | 10 | namespace ProductLaunch.Web { 11 | 12 | 13 | public partial class ViewSwitcher { 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Web.Debug.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 29 | 30 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Web.Release.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 19 | 30 | 31 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/favicon.ico -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/ProductLaunch.Web/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/ProductLaunch/build.ps1: -------------------------------------------------------------------------------- 1 | $nuGetPath = "C:\Chocolatey\bin\nuget.bat" 2 | $msBuildPath = "C:\Program Files (x86)\MSBuild\14.0\Bin\MSBuild.exe" 3 | 4 | cd c:\src 5 | & $nuGetPath restore .\ProductLaunch.sln 6 | 7 | # publush web app: 8 | & $msBuildPath .\ProductLaunch.Web\ProductLaunch.Web.csproj /p:OutputPath=c:\out\web\ProductLaunchWeb /p:DeployOnBuild=true /p:VSToolsPath=C:\MSBuild.Microsoft.VisualStudio.Web.targets.14.0.0.3\tools\VSToolsPath 9 | 10 | # publish message handler: 11 | & $msBuildPath .\ProductLaunch.MessageHandlers.SaveProspect\ProductLaunch.MessageHandlers.SaveProspect.csproj /p:OutputPath=c:\out\save-prospect\SaveProspectHandler 12 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/build.ps1: -------------------------------------------------------------------------------- 1 | [CmdletBinding()] 2 | Param( 3 | [Parameter(Mandatory=$True,Position=1)] 4 | [string] $dockerID 5 | ) 6 | 7 | docker build ` 8 | -t $dockerID/modernize-aspnet-builder ` 9 | $pwd\docker\builder 10 | 11 | docker run --rm ` 12 | -v $pwd\ProductLaunch:c:\src ` 13 | -v $pwd\docker:c:\out ` 14 | $dockerID/modernize-aspnet-builder ` 15 | C:\src\build.ps1 16 | 17 | docker build ` 18 | -t $dockerID/modernize-aspnet-web:v2 ` 19 | $pwd\docker\web 20 | 21 | docker build ` 22 | -t $dockerID/modernize-aspnet-handler:v2 ` 23 | $pwd\docker\save-prospect -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '3' 2 | 3 | services: 4 | 5 | product-launch-db: 6 | image: microsoft/mssql-server-windows-express 7 | ports: 8 | - "1433:1433" 9 | environment: 10 | - ACCEPT_EULA=Y 11 | - sa_password=d0ck3r_Labs! 12 | networks: 13 | - app-net 14 | 15 | message-queue: 16 | image: nats:nanoserver 17 | ports: 18 | - "4222:4222" 19 | networks: 20 | - app-net 21 | 22 | product-launch-web: 23 | image: /modernize-aspnet-web:v2 24 | ports: 25 | - "80:80" 26 | environment: 27 | - DB_CONNECTION_STRING=Server=product-launch-db;Database=ProductLaunch;User Id=sa;Password=d0ck3r_Labs!; 28 | depends_on: 29 | - product-launch-db 30 | - message-queue 31 | networks: 32 | - app-net 33 | 34 | save-prospect-handler: 35 | image: /modernize-aspnet-handler:v2 36 | environment: 37 | - DB_CONNECTION_STRING=Server=product-launch-db;Database=ProductLaunch;User Id=sa;Password=d0ck3r_Labs!; 38 | depends_on: 39 | - product-launch-db 40 | - message-queue 41 | networks: 42 | - app-net 43 | 44 | networks: 45 | app-net: 46 | external: 47 | name: nat 48 | -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/docker/builder/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/windowsservercore:10.0.14393.693 3 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 4 | 5 | RUN Install-PackageProvider -Name chocolatey -RequiredVersion 2.8.5.130 -Force; ` 6 | Install-Package -Name microsoft-build-tools -RequiredVersion 14.0.25420.1 -Force; ` 7 | Install-Package -Name netfx-4.5.2-devpack -RequiredVersion 4.5.5165101 -Force; ` 8 | Install-Package -Name webdeploy -RequiredVersion 3.5.2 -Force 9 | 10 | RUN Install-Package -Name nuget.commandline -RequiredVersion 3.4.3 -Force; ` 11 | & C:\Chocolatey\bin\nuget install MSBuild.Microsoft.VisualStudio.Web.targets -Version 14.0.0.3 12 | 13 | ENTRYPOINT ["powershell"] -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/docker/save-prospect/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/windowsservercore:10.0.14393.693 3 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 4 | 5 | RUN Set-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Services\Dnscache\Parameters' -Name ServerPriorityTimeLimit -Value 0 -Type DWord 6 | 7 | WORKDIR /save-prospect-handler 8 | ENV MESSAGE_QUEUE_URL="nats://message-queue:4222" 9 | ENTRYPOINT ["C:\\save-prospect-handler\\ProductLaunch.MessageHandlers.SaveProspect.exe"] 10 | 11 | COPY SaveProspectHandler . -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/docker/web/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/aspnet:windowsservercore-10.0.14393.693 3 | SHELL ["powershell", "-Command", "$ErrorActionPreference = 'Stop'; $ProgressPreference = 'SilentlyContinue';"] 4 | 5 | RUN Set-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Services\Dnscache\Parameters' -Name ServerPriorityTimeLimit -Value 0 -Type DWord 6 | 7 | RUN Remove-Website -Name 'Default Web Site'; ` 8 | New-Item -Path 'C:\web-app' -Type Directory; ` 9 | New-Website -Name 'web-app' -PhysicalPath 'C:\web-app' -Port 80 -Force 10 | 11 | ENV MESSAGE_QUEUE_URL="nats://message-queue:4222" 12 | ENTRYPOINT ["powershell", "./bootstrap.ps1"] 13 | 14 | COPY bootstrap.ps1 / 15 | COPY ProductLaunchWeb/_PublishedWebsites/ProductLaunch.Web /web-app 16 | 17 | HEALTHCHECK CMD powershell -command ` 18 | try { ` 19 | $response = iwr http://localhost:80 -UseBasicParsing; ` 20 | if ($response.StatusCode -eq 200) { return 0} ` 21 | else {return 1}; ` 22 | } catch { return 1 } -------------------------------------------------------------------------------- /windows-modernize-aspnet-dev/v2-src/docker/web/bootstrap.ps1: -------------------------------------------------------------------------------- 1 | Write-Output 'Bootstrap starting' 2 | 3 | # copy process-level environment variables (from `docker run`) machine-wide 4 | foreach($key in [System.Environment]::GetEnvironmentVariables('Process').Keys) { 5 | if ([System.Environment]::GetEnvironmentVariable($key, 'Machine') -eq $null) { 6 | $value = [System.Environment]::GetEnvironmentVariable($key, 'Process') 7 | [System.Environment]::SetEnvironmentVariable($key, $value, 'Machine') 8 | Write-Output "Set environment variable: $key" 9 | } 10 | } 11 | 12 | Write-Output 'Running ServiceMonitor' 13 | & C:\ServiceMonitor.exe w3svc -------------------------------------------------------------------------------- /windows-modernize-aspnet-ops/images/app-v1.0.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-ops/images/app-v1.0.png -------------------------------------------------------------------------------- /windows-modernize-aspnet-ops/images/app-v1.1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-ops/images/app-v1.1.png -------------------------------------------------------------------------------- /windows-modernize-aspnet-ops/v1.0/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/aspnet:windowsservercore-10.0.14393.576 3 | 4 | COPY UpgradeSample-1.0.0.0.msi / 5 | 6 | RUN msiexec /i c:\UpgradeSample-1.0.0.0.msi RELEASENAME=2017.02 /qn -------------------------------------------------------------------------------- /windows-modernize-aspnet-ops/v1.0/UpgradeSample-1.0.0.0.msi: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-ops/v1.0/UpgradeSample-1.0.0.0.msi -------------------------------------------------------------------------------- /windows-modernize-aspnet-ops/v1.1/Dockerfile: -------------------------------------------------------------------------------- 1 | # escape=` 2 | FROM microsoft/aspnet:windowsservercore-10.0.14393.693 3 | 4 | COPY UpgradeSample-1.1.0.0.msi / 5 | 6 | RUN msiexec /i c:\UpgradeSample-1.1.0.0.msi RELEASENAME=2017.03 /qn -------------------------------------------------------------------------------- /windows-modernize-aspnet-ops/v1.1/UpgradeSample-1.1.0.0.msi: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/docker-archive/dcus-hol-2017/6bb72a7bd4292756adc842a0819628837694018c/windows-modernize-aspnet-ops/v1.1/UpgradeSample-1.1.0.0.msi --------------------------------------------------------------------------------