├── .gitignore ├── CONTRIBUTING.md ├── Common └── images │ ├── Java-Jdk.png │ ├── Lab-06-appmanager-1.png │ ├── Lab-06-appmanager-2.png │ ├── Lab-06-appmanager-3.png │ ├── Lab-07-appmanager-2.png │ ├── Lab-07-appmanager-3.png │ ├── blue-green.png │ ├── lab-01-application-config.png │ ├── lab-01-appsmanager-env-variables.png │ ├── lab-01-appsmanager-env.png │ ├── lab-01-appsmanager.png │ ├── lab-01-cloudfoundry-config.png │ ├── lab-01-dotnet-install.png │ ├── lab-01-dotnet-install2.png │ ├── lab-01-git-hub.png │ ├── lab-01-raw-config.png │ ├── lab-01-subsection-config.png │ ├── lab-02-cloudfoundry-config.png │ ├── lab-05-fortuneservice-all.png │ ├── lab-05-ui.png │ ├── lab-05-ui2.png │ ├── lab-05-ui3.png │ ├── lab-09-hystrix-1.png │ ├── lab-09-hystrix-2.png │ ├── lab-add-route.png │ ├── lab-app-db.png │ ├── lab-app-service.png │ ├── lab-kill-button.png │ ├── lab-kill-failed.png │ ├── lab-kill-ok.png │ ├── lab-log4net-nuget.png │ ├── lab-marketplace.png │ ├── lab-metrics-sel.png │ ├── lab-metrics.png │ ├── lab-mkt-link.png │ ├── lab-mvcattendees.png │ ├── lab-mvcattendeesrunning.png │ ├── lab-mysql.png │ ├── lab-mysql2.png │ ├── lab-mysql3.png │ ├── lab-mysql4.png │ ├── lab-mysql5.png │ ├── lab-net.png │ ├── lab-new-route.png │ ├── lab-no-route.png │ ├── lab-routes.png │ ├── lab-scale-down.png │ ├── lab-scale-up.png │ ├── lab-student-loggedin.png │ ├── lab-student-login.png │ └── lab-unmap-route.png ├── ConfigServer ├── .gitignore ├── .mvn │ ├── jvm.config │ └── wrapper │ │ ├── maven-wrapper.jar │ │ └── maven-wrapper.properties ├── Dockerfile ├── README.md ├── mvnw ├── mvnw.cmd ├── pom.xml ├── src │ ├── main │ │ ├── docker │ │ │ └── Dockerfile │ │ ├── java │ │ │ └── demo │ │ │ │ └── ConfigServerApplication.java │ │ └── resources │ │ │ ├── application.yml │ │ │ ├── bootstrap.yml │ │ │ └── keystore.jks │ └── test │ │ └── java │ │ └── demo │ │ └── ApplicationTests.java └── steeltoe │ └── config-repo │ ├── application-development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── EurekaServer ├── .gitignore ├── .mvn │ ├── jvm.config │ └── wrapper │ │ ├── maven-wrapper.jar │ │ └── maven-wrapper.properties ├── .travis.yml ├── Dockerfile ├── README.md ├── build.gradle ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── mvnw ├── mvnw.cmd ├── pom.xml ├── settings.gradle └── src │ ├── main │ ├── docker │ │ └── Dockerfile │ ├── java │ │ └── eurekademo │ │ │ └── EurekaApplication.java │ └── resources │ │ ├── application.yml │ │ └── bootstrap.yml │ └── test │ └── java │ └── eurekademo │ └── ApplicationTests.java ├── Final ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── MySqlHealthContributor.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── git.properties │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceCommand.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── git.properties │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createClient.cmd │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── LICENSE ├── Lab00 └── README.md ├── Lab01 ├── CloudFoundry │ ├── .bowerrc │ ├── AppConfigurationOptions.cs │ ├── CloudFoundry.csproj │ ├── Controllers │ │ └── HomeController.cs │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── SubSectionConfigurationOptions.cs │ ├── TagHelpers │ │ └── CloudFoundryServiceCredentials.cs │ ├── ViewModels │ │ ├── AppConfigViewModel.cs │ │ ├── CloudFoundryViewModel.cs │ │ └── SubSectionConfigViewModel.cs │ ├── Views │ │ ├── Home │ │ │ ├── AppConfig.cshtml │ │ │ ├── CloudFoundryConfig.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── RawConfig.cshtml │ │ │ └── SubSectionConfig.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── Lab01.sln ├── README.md └── nuget.config ├── Lab02 └── README.md ├── Lab03 └── README.md ├── Lab04 └── README.md ├── Lab05 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── Lab06 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── Lab07 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── Lab08 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── Lab09 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceCommand.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── Lab10 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceCommand.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── Lab11 ├── Fortune-Teller-Service │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-Service.csproj │ ├── Models │ │ ├── Fortune.cs │ │ ├── FortuneContext.cs │ │ ├── FortuneEntity.cs │ │ ├── FortuneRepository.cs │ │ ├── IFortuneRepository.cs │ │ └── SampleData.cs │ ├── MySqlHealthContributor.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Startup.cs │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── git.properties │ ├── manifest-windows.yml │ ├── manifest.yml │ └── nuget.config ├── Fortune-Teller-UI │ ├── .bowerrc │ ├── Controllers │ │ └── FortunesController.cs │ ├── Fortune-Teller-UI.csproj │ ├── Models │ │ └── ErrorViewModel.cs │ ├── Program.cs │ ├── Properties │ │ └── launchSettings.json │ ├── Services │ │ ├── Fortune.cs │ │ ├── FortuneServiceClient.cs │ │ ├── FortuneServiceCommand.cs │ │ ├── FortuneServiceOptions.cs │ │ └── IFortuneService.cs │ ├── Startup.cs │ ├── Views │ │ ├── Fortunes │ │ │ ├── AccessDenied.cshtml │ │ │ ├── Index.cshtml │ │ │ ├── Manage.cshtml │ │ │ └── RandomFortune.cshtml │ │ ├── Shared │ │ │ ├── Error.cshtml │ │ │ ├── _Layout.cshtml │ │ │ ├── _LoginPartial.cshtml │ │ │ └── _ValidationScriptsPartial.cshtml │ │ ├── _ViewImports.cshtml │ │ └── _ViewStart.cshtml │ ├── appsettings.Development.json │ ├── appsettings.json │ ├── bower.json │ ├── bundleconfig.json │ ├── git.properties │ ├── manifest-windows.yml │ ├── manifest.yml │ ├── nuget.config │ └── wwwroot │ │ ├── css │ │ ├── site.css │ │ └── site.min.css │ │ ├── favicon.ico │ │ ├── images │ │ ├── banner1.svg │ │ ├── banner2.svg │ │ ├── banner3.svg │ │ └── banner4.svg │ │ ├── js │ │ ├── site.js │ │ └── site.min.js │ │ └── lib │ │ ├── bootstrap │ │ ├── .bower.json │ │ ├── LICENSE │ │ └── dist │ │ │ ├── css │ │ │ ├── bootstrap-theme.css │ │ │ ├── bootstrap-theme.css.map │ │ │ ├── bootstrap-theme.min.css │ │ │ ├── bootstrap-theme.min.css.map │ │ │ ├── bootstrap.css │ │ │ ├── bootstrap.css.map │ │ │ ├── bootstrap.min.css │ │ │ └── bootstrap.min.css.map │ │ │ ├── fonts │ │ │ ├── glyphicons-halflings-regular.eot │ │ │ ├── glyphicons-halflings-regular.svg │ │ │ ├── glyphicons-halflings-regular.ttf │ │ │ ├── glyphicons-halflings-regular.woff │ │ │ └── glyphicons-halflings-regular.woff2 │ │ │ └── js │ │ │ ├── bootstrap.js │ │ │ ├── bootstrap.min.js │ │ │ └── npm.js │ │ ├── jquery-validation-unobtrusive │ │ ├── .bower.json │ │ ├── jquery.validate.unobtrusive.js │ │ └── jquery.validate.unobtrusive.min.js │ │ ├── jquery-validation │ │ ├── .bower.json │ │ ├── LICENSE.md │ │ └── dist │ │ │ ├── additional-methods.js │ │ │ ├── additional-methods.min.js │ │ │ ├── jquery.validate.js │ │ │ └── jquery.validate.min.js │ │ └── jquery │ │ ├── .bower.json │ │ ├── LICENSE.txt │ │ └── dist │ │ ├── jquery.js │ │ ├── jquery.min.js │ │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo │ ├── application-Development.yml │ ├── application.yml │ ├── fortuneService.yml │ └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts │ ├── config-server.json │ ├── createCloudFoundryServices.cmd │ ├── createCloudFoundryServices.sh │ ├── deleteCloudFoundryServices.cmd │ └── deleteCloudFoundryServices.sh ├── README.md ├── Slides └── Workshop.pdf └── Start ├── Fortune-Teller-Service ├── Controllers │ └── FortunesController.cs ├── Fortune-Teller-Service.csproj ├── Models │ ├── Fortune.cs │ ├── FortuneContext.cs │ ├── FortuneEntity.cs │ ├── FortuneRepository.cs │ ├── IFortuneRepository.cs │ └── SampleData.cs ├── Program.cs ├── Properties │ └── launchSettings.json ├── Startup.cs ├── appsettings.Development.json ├── appsettings.json ├── manifest-windows.yml ├── manifest.yml └── nuget.config ├── Fortune-Teller-UI ├── .bowerrc ├── Controllers │ └── FortunesController.cs ├── Fortune-Teller-UI.csproj ├── Models │ └── ErrorViewModel.cs ├── Program.cs ├── Properties │ └── launchSettings.json ├── Services │ ├── Fortune.cs │ ├── FortuneServiceClient.cs │ ├── FortuneServiceOptions.cs │ └── IFortuneService.cs ├── Startup.cs ├── Views │ ├── Fortunes │ │ ├── AccessDenied.cshtml │ │ ├── Index.cshtml │ │ ├── Manage.cshtml │ │ └── RandomFortune.cshtml │ ├── Shared │ │ ├── Error.cshtml │ │ ├── _Layout.cshtml │ │ ├── _LoginPartial.cshtml │ │ └── _ValidationScriptsPartial.cshtml │ ├── _ViewImports.cshtml │ └── _ViewStart.cshtml ├── appsettings.Development.json ├── appsettings.json ├── bower.json ├── bundleconfig.json ├── manifest-windows.yml ├── manifest.yml ├── nuget.config └── wwwroot │ ├── css │ ├── site.css │ └── site.min.css │ ├── favicon.ico │ ├── images │ ├── banner1.svg │ ├── banner2.svg │ ├── banner3.svg │ └── banner4.svg │ ├── js │ ├── site.js │ └── site.min.js │ └── lib │ ├── bootstrap │ ├── .bower.json │ ├── LICENSE │ └── dist │ │ ├── css │ │ ├── bootstrap-theme.css │ │ ├── bootstrap-theme.css.map │ │ ├── bootstrap-theme.min.css │ │ ├── bootstrap-theme.min.css.map │ │ ├── bootstrap.css │ │ ├── bootstrap.css.map │ │ ├── bootstrap.min.css │ │ └── bootstrap.min.css.map │ │ ├── fonts │ │ ├── glyphicons-halflings-regular.eot │ │ ├── glyphicons-halflings-regular.svg │ │ ├── glyphicons-halflings-regular.ttf │ │ ├── glyphicons-halflings-regular.woff │ │ └── glyphicons-halflings-regular.woff2 │ │ └── js │ │ ├── bootstrap.js │ │ ├── bootstrap.min.js │ │ └── npm.js │ ├── jquery-validation-unobtrusive │ ├── .bower.json │ ├── jquery.validate.unobtrusive.js │ └── jquery.validate.unobtrusive.min.js │ ├── jquery-validation │ ├── .bower.json │ ├── LICENSE.md │ └── dist │ │ ├── additional-methods.js │ │ ├── additional-methods.min.js │ │ ├── jquery.validate.js │ │ └── jquery.validate.min.js │ └── jquery │ ├── .bower.json │ ├── LICENSE.txt │ └── dist │ ├── jquery.js │ ├── jquery.min.js │ └── jquery.min.map ├── FortuneTeller.sln ├── README.md ├── config-repo ├── application-Development.yml ├── application.yml ├── fortuneService.yml └── fortuneui.yml ├── config-server.json ├── nuget.config └── scripts ├── config-server.json ├── createCloudFoundryServices.cmd ├── createCloudFoundryServices.sh ├── deleteCloudFoundryServices.cmd └── deleteCloudFoundryServices.sh /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | If you have not previously done so, please fill out and 2 | submit the [Contributor License Agreement](https://cla.pivotal.io/sign/pivotal). 3 | -------------------------------------------------------------------------------- /Common/images/Java-Jdk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/Java-Jdk.png -------------------------------------------------------------------------------- /Common/images/Lab-06-appmanager-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/Lab-06-appmanager-1.png -------------------------------------------------------------------------------- /Common/images/Lab-06-appmanager-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/Lab-06-appmanager-2.png -------------------------------------------------------------------------------- /Common/images/Lab-06-appmanager-3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/Lab-06-appmanager-3.png -------------------------------------------------------------------------------- /Common/images/Lab-07-appmanager-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/Lab-07-appmanager-2.png -------------------------------------------------------------------------------- /Common/images/Lab-07-appmanager-3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/Lab-07-appmanager-3.png -------------------------------------------------------------------------------- /Common/images/blue-green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/blue-green.png -------------------------------------------------------------------------------- /Common/images/lab-01-application-config.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-application-config.png -------------------------------------------------------------------------------- /Common/images/lab-01-appsmanager-env-variables.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-appsmanager-env-variables.png -------------------------------------------------------------------------------- /Common/images/lab-01-appsmanager-env.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-appsmanager-env.png -------------------------------------------------------------------------------- /Common/images/lab-01-appsmanager.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-appsmanager.png -------------------------------------------------------------------------------- /Common/images/lab-01-cloudfoundry-config.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-cloudfoundry-config.png -------------------------------------------------------------------------------- /Common/images/lab-01-dotnet-install.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-dotnet-install.png -------------------------------------------------------------------------------- /Common/images/lab-01-dotnet-install2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-dotnet-install2.png -------------------------------------------------------------------------------- /Common/images/lab-01-git-hub.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-git-hub.png -------------------------------------------------------------------------------- /Common/images/lab-01-raw-config.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-raw-config.png -------------------------------------------------------------------------------- /Common/images/lab-01-subsection-config.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-01-subsection-config.png -------------------------------------------------------------------------------- /Common/images/lab-02-cloudfoundry-config.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-02-cloudfoundry-config.png -------------------------------------------------------------------------------- /Common/images/lab-05-fortuneservice-all.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-05-fortuneservice-all.png -------------------------------------------------------------------------------- /Common/images/lab-05-ui.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-05-ui.png -------------------------------------------------------------------------------- /Common/images/lab-05-ui2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-05-ui2.png -------------------------------------------------------------------------------- /Common/images/lab-05-ui3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-05-ui3.png -------------------------------------------------------------------------------- /Common/images/lab-09-hystrix-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-09-hystrix-1.png -------------------------------------------------------------------------------- /Common/images/lab-09-hystrix-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-09-hystrix-2.png -------------------------------------------------------------------------------- /Common/images/lab-add-route.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-add-route.png -------------------------------------------------------------------------------- /Common/images/lab-app-db.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-app-db.png -------------------------------------------------------------------------------- /Common/images/lab-app-service.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-app-service.png -------------------------------------------------------------------------------- /Common/images/lab-kill-button.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-kill-button.png -------------------------------------------------------------------------------- /Common/images/lab-kill-failed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-kill-failed.png -------------------------------------------------------------------------------- /Common/images/lab-kill-ok.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-kill-ok.png -------------------------------------------------------------------------------- /Common/images/lab-log4net-nuget.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-log4net-nuget.png -------------------------------------------------------------------------------- /Common/images/lab-marketplace.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-marketplace.png -------------------------------------------------------------------------------- /Common/images/lab-metrics-sel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-metrics-sel.png -------------------------------------------------------------------------------- /Common/images/lab-metrics.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-metrics.png -------------------------------------------------------------------------------- /Common/images/lab-mkt-link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mkt-link.png -------------------------------------------------------------------------------- /Common/images/lab-mvcattendees.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mvcattendees.png -------------------------------------------------------------------------------- /Common/images/lab-mvcattendeesrunning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mvcattendeesrunning.png -------------------------------------------------------------------------------- /Common/images/lab-mysql.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mysql.png -------------------------------------------------------------------------------- /Common/images/lab-mysql2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mysql2.png -------------------------------------------------------------------------------- /Common/images/lab-mysql3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mysql3.png -------------------------------------------------------------------------------- /Common/images/lab-mysql4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mysql4.png -------------------------------------------------------------------------------- /Common/images/lab-mysql5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-mysql5.png -------------------------------------------------------------------------------- /Common/images/lab-net.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-net.png -------------------------------------------------------------------------------- /Common/images/lab-new-route.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-new-route.png -------------------------------------------------------------------------------- /Common/images/lab-no-route.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-no-route.png -------------------------------------------------------------------------------- /Common/images/lab-routes.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-routes.png -------------------------------------------------------------------------------- /Common/images/lab-scale-down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-scale-down.png -------------------------------------------------------------------------------- /Common/images/lab-scale-up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-scale-up.png -------------------------------------------------------------------------------- /Common/images/lab-student-loggedin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-student-loggedin.png -------------------------------------------------------------------------------- /Common/images/lab-student-login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-student-login.png -------------------------------------------------------------------------------- /Common/images/lab-unmap-route.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Common/images/lab-unmap-route.png -------------------------------------------------------------------------------- /ConfigServer/.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | #* 3 | *# 4 | .#* 5 | .classpath 6 | .project 7 | .settings 8 | .springBeans 9 | .gradle 10 | build 11 | bin 12 | /target/ 13 | git.properties 14 | .idea 15 | *.iml 16 | .factorypath 17 | -------------------------------------------------------------------------------- /ConfigServer/.mvn/jvm.config: -------------------------------------------------------------------------------- 1 | -Xmx1024m -XX:CICompilerCount=1 -XX:TieredStopAtLevel=1 -Djava.security.egd=file:/dev/./urandom -------------------------------------------------------------------------------- /ConfigServer/.mvn/wrapper/maven-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/ConfigServer/.mvn/wrapper/maven-wrapper.jar -------------------------------------------------------------------------------- /ConfigServer/.mvn/wrapper/maven-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.3.9/apache-maven-3.3.9-bin.zip -------------------------------------------------------------------------------- /ConfigServer/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM java:8 2 | ADD target/configserver-0.0.1-SNAPSHOT.jar app.jar 3 | VOLUME /steeltoe/config-repo 4 | EXPOSE 8888 5 | ENTRYPOINT ["java","-jar","/app.jar"] -------------------------------------------------------------------------------- /ConfigServer/README.md: -------------------------------------------------------------------------------- 1 | # Spring Cloud Config Server for Workshop Labs 2 | 3 | To startup a Spring Cloud Config Server, run this project as a Spring Boot app by issuing: 4 | 5 | ``` 6 | $ ./mvnw spring-boot:run 7 | ``` 8 | 9 | or 10 | 11 | ``` 12 | $ ./mvnw package 13 | $ java -jar target/*.jar 14 | ``` 15 | 16 | It will start up on port 8888 and serve configuration data from 17 | "file:./steeltoe/config-repo": -------------------------------------------------------------------------------- /ConfigServer/src/main/docker/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM steeltoe:openjdk-servercore 2 | ADD configserver-0.0.1-SNAPSHOT.jar app.jar 3 | EXPOSE 8888 4 | ENTRYPOINT ["java","-jar","/app.jar"] -------------------------------------------------------------------------------- /ConfigServer/src/main/java/demo/ConfigServerApplication.java: -------------------------------------------------------------------------------- 1 | package demo; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.EnableAutoConfiguration; 5 | import org.springframework.cloud.client.discovery.EnableDiscoveryClient; 6 | import org.springframework.cloud.config.server.EnableConfigServer; 7 | import org.springframework.context.annotation.Configuration; 8 | 9 | @Configuration 10 | @EnableAutoConfiguration 11 | @EnableDiscoveryClient 12 | @EnableConfigServer 13 | public class ConfigServerApplication { 14 | 15 | public static void main(String[] args) { 16 | SpringApplication.run(ConfigServerApplication.class, args); 17 | } 18 | 19 | } 20 | -------------------------------------------------------------------------------- /ConfigServer/src/main/resources/application.yml: -------------------------------------------------------------------------------- 1 | server: 2 | port: 8888 3 | 4 | management: 5 | context-path: /admin 6 | 7 | logging: 8 | level: 9 | org.springframework.cloud: 'DEBUG' 10 | 11 | spring: 12 | profiles: 13 | active: native 14 | cloud: 15 | config: 16 | server: 17 | native: 18 | searchLocations: file:./steeltoe/config-repo 19 | # 20 | # Replace spring: configuration above with what is below for github repo usage 21 | # 22 | # spring: 23 | # cloud: 24 | # config: 25 | # server: 26 | # git: https://github.com/SteeltoeOSS/workshop-config-repo.git -------------------------------------------------------------------------------- /ConfigServer/src/main/resources/bootstrap.yml: -------------------------------------------------------------------------------- 1 | spring: 2 | application: 3 | name: configserver 4 | encrypt: 5 | failOnError: false 6 | keyStore: 7 | location: classpath:keystore.jks 8 | password: ${KEYSTORE_PASSWORD:foobar} # don't use a default in production 9 | alias: test 10 | -------------------------------------------------------------------------------- /ConfigServer/src/main/resources/keystore.jks: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/ConfigServer/src/main/resources/keystore.jks -------------------------------------------------------------------------------- /ConfigServer/steeltoe/config-repo/application-development.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/ConfigServer/steeltoe/config-repo/application-development.yml -------------------------------------------------------------------------------- /ConfigServer/steeltoe/config-repo/application.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/ConfigServer/steeltoe/config-repo/application.yml -------------------------------------------------------------------------------- /ConfigServer/steeltoe/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/ConfigServer/steeltoe/config-repo/fortuneService.yml -------------------------------------------------------------------------------- /ConfigServer/steeltoe/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/ConfigServer/steeltoe/config-repo/fortuneui.yml -------------------------------------------------------------------------------- /EurekaServer/.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | #* 3 | *# 4 | .#* 5 | .classpath 6 | .project 7 | .settings 8 | .springBeans 9 | .gradle 10 | build 11 | bin 12 | /target/ 13 | git.properties 14 | .idea 15 | *.iml 16 | .factorypath 17 | -------------------------------------------------------------------------------- /EurekaServer/.mvn/jvm.config: -------------------------------------------------------------------------------- 1 | -Xmx1024m -XX:CICompilerCount=1 -XX:TieredStopAtLevel=1 -Djava.security.egd=file:/dev/./urandom -------------------------------------------------------------------------------- /EurekaServer/.mvn/wrapper/maven-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/EurekaServer/.mvn/wrapper/maven-wrapper.jar -------------------------------------------------------------------------------- /EurekaServer/.mvn/wrapper/maven-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.3.3/apache-maven-3.3.3-bin.zip -------------------------------------------------------------------------------- /EurekaServer/.travis.yml: -------------------------------------------------------------------------------- 1 | language: java 2 | before_install: 3 | - chmod +x gradlew 4 | -------------------------------------------------------------------------------- /EurekaServer/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM java:8 2 | ADD target/eureka-0.0.1-SNAPSHOT.jar app.jar 3 | EXPOSE 8761 4 | ENTRYPOINT ["java","-jar","/app.jar"] -------------------------------------------------------------------------------- /EurekaServer/README.md: -------------------------------------------------------------------------------- 1 | # Eureka Server for Workshop Labs 2 | 3 | To startup a Eureka Server, run this project as a Spring Boot app by issuing: 4 | 5 | ``` 6 | $ ./mvnw spring-boot:run 7 | ``` 8 | It will start up on port 8761 and serve the Eureka API from "/eureka". 9 | 10 | -------------------------------------------------------------------------------- /EurekaServer/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/EurekaServer/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /EurekaServer/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Sun Mar 22 23:42:25 MSK 2015 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.3-bin.zip 7 | -------------------------------------------------------------------------------- /EurekaServer/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'eureka' 2 | -------------------------------------------------------------------------------- /EurekaServer/src/main/docker/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM java:7 2 | VOLUME /tmp 3 | ADD eureka-0.0.1-SNAPSHOT.jar /app.jar 4 | RUN bash -c 'touch /app.jar' 5 | EXPOSE 8761 6 | ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.jar"] -------------------------------------------------------------------------------- /EurekaServer/src/main/java/eurekademo/EurekaApplication.java: -------------------------------------------------------------------------------- 1 | package eurekademo; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.cloud.client.discovery.EnableDiscoveryClient; 6 | import org.springframework.cloud.netflix.eureka.server.EnableEurekaServer; 7 | 8 | /** 9 | * 10 | * @author Gunnar Hillert 11 | * 12 | */ 13 | @SpringBootApplication 14 | @EnableEurekaServer 15 | @EnableDiscoveryClient 16 | public class EurekaApplication { 17 | 18 | public static void main(String[] args) throws Exception { 19 | SpringApplication.run(EurekaApplication.class, args); 20 | } 21 | 22 | } 23 | -------------------------------------------------------------------------------- /EurekaServer/src/main/resources/application.yml: -------------------------------------------------------------------------------- 1 | server: 2 | port: 8761 3 | 4 | eureka: 5 | client: 6 | registerWithEureka: false 7 | fetchRegistry: false 8 | server: 9 | waitTimeInMsWhenSyncEmpty: 0 10 | -------------------------------------------------------------------------------- /EurekaServer/src/main/resources/bootstrap.yml: -------------------------------------------------------------------------------- 1 | spring: 2 | application: 3 | name: eureka 4 | cloud: 5 | config: 6 | uri: ${CONFIG_SERVER_URL:http://localhost:9999} 7 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/git.properties: -------------------------------------------------------------------------------- 1 | git.remote.origin.url=C:/workspace/Workshop 2 | git.build.version=0.1.0 3 | git.commit.id.abbrev=432f40e 4 | git.commit.id=432f40e7af3dc190fdeb89715476216de67bd751 5 | git.tags= 6 | git.branch=2.0 7 | git.build.time=2017-11-28T05:53:58.9373824-07:00 8 | git.build.user.name=dtillman 9 | git.build.host=DESKTOP-D0GL5GA 10 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myMySqlService 15 | - myOAuthService 16 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myMySqlService 12 | - myOAuthService -------------------------------------------------------------------------------- /Final/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Properties/launchSettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "iisSettings": { 3 | "windowsAuthentication": false, 4 | "anonymousAuthentication": true, 5 | "iisExpress": { 6 | "applicationUrl": "http://localhost:58490/", 7 | "sslPort": 0 8 | } 9 | }, 10 | "profiles": { 11 | "IIS Express": { 12 | "commandName": "IISExpress", 13 | "launchBrowser": true, 14 | "environmentVariables": { 15 | "ASPNETCORE_ENVIRONMENT": "Development" 16 | } 17 | }, 18 | "Fortune_Teller_UI": { 19 | "commandName": "Project", 20 | "environmentVariables": { 21 | "ASPNETCORE_ENVIRONMENT": "Development", 22 | "ASPNETCORE_URLS": "http://*:5555" 23 | } 24 | 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/git.properties: -------------------------------------------------------------------------------- 1 | git.remote.origin.url=C:/workspace/Workshop 2 | git.build.version=0.1.0 3 | git.commit.id.abbrev=432f40e 4 | git.commit.id=432f40e7af3dc190fdeb89715476216de67bd751 5 | git.tags= 6 | git.branch=2.0 7 | git.build.time=2017-11-28T05:54:37.4419120-07:00 8 | git.build.user.name=dtillman 9 | git.build.host=DESKTOP-D0GL5GA 10 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myRedisService 15 | - myHystrixService 16 | - myOAuthService -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myRedisService 12 | - myHystrixService 13 | - myOAuthService -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Final/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Final/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Final/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Final/README.md: -------------------------------------------------------------------------------- 1 | # Workshop Final Code 2 | 3 | Here you will find the final workshop code. -------------------------------------------------------------------------------- /Final/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Final/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information 9 | eureka: 10 | client: 11 | serviceUrl: http://localhost:8761/eureka/ 12 | validate_certificates: false 13 | security: 14 | oauth2: 15 | client: 16 | validate_certificates: false 17 | management: 18 | endpoints: 19 | path: /cloudfoundryapplication 20 | cloudfoundry: 21 | validateCertificates: false -------------------------------------------------------------------------------- /Final/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldFetchRegistry: false 4 | instance: 5 | port: 5000 6 | mysql: 7 | client: 8 | database: mydatabase 9 | username: username 10 | password: password 11 | -------------------------------------------------------------------------------- /Final/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldRegisterWithEureka: false 4 | hystrix: 5 | stream: 6 | validate_certificates: false 7 | fortuneService: 8 | scheme: http 9 | address: fortuneservice 10 | randomFortunePath: api/fortunes/random 11 | allFortunesPath: api/fortunes/all 12 | 13 | -------------------------------------------------------------------------------- /Final/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Final/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Final/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Final/scripts/createClient.cmd: -------------------------------------------------------------------------------- 1 | uaac client add dave1App --scope cloud_controller.read,cloud_controller_service_permissions.read,openid,read.fortunes --authorized_grant_types authorization_code,refresh_token --authorities uaa.resource --redirect_uri http://fortuneui-*-*.apps.selma.cf-app.com/signin-cloudfoundry --autoapprove cloud_controller.read,cloud_controller_service_permissions.read,openid,read.fortunes --secret dave1Secret 2 | -------------------------------------------------------------------------------- /Final/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"dave1App\",\"client_secret\": \"dave1Secret\",\"uri\": \"uaa://login.sys.selma.cf-app.com\"}" 9 | -------------------------------------------------------------------------------- /Final/scripts/createCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p `{"client_id": "myTestApp","client_secret": "myTestApp","uri": "uaa://login.system.testcloud.com"}' -------------------------------------------------------------------------------- /Final/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Final/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab01/CloudFoundry/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/AppConfigurationOptions.cs: -------------------------------------------------------------------------------- 1 | namespace CloudFoundry 2 | { 3 | public class AppConfigurationOptions 4 | { 5 | public AppConfigurationOptions() 6 | { 7 | // Set default value. 8 | Option1 = "value1_from_ctor"; 9 | } 10 | public string Option1 { get; set; } 11 | public int Option2 { get; set; } = 5; 12 | 13 | } 14 | } -------------------------------------------------------------------------------- /Lab01/CloudFoundry/CloudFoundry.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.0 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | // Lab01 - Lab04 Start 2 | 3 | using System; 4 | 5 | namespace CloudFoundry.Models 6 | { 7 | public class ErrorViewModel 8 | { 9 | public string RequestId { get; set; } 10 | 11 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 12 | } 13 | } 14 | // Lab01 - Lab04 End -------------------------------------------------------------------------------- /Lab01/CloudFoundry/SubSectionConfigurationOptions.cs: -------------------------------------------------------------------------------- 1 | namespace CloudFoundry 2 | { 3 | public class SubSectionConfigurationOptions 4 | { 5 | public string Suboption1 { get; set; } 6 | } 7 | } -------------------------------------------------------------------------------- /Lab01/CloudFoundry/ViewModels/AppConfigViewModel.cs: -------------------------------------------------------------------------------- 1 | 2 | // Lab01 - Lab04 Start 3 | 4 | namespace CloudFoundry.ViewModels 5 | { 6 | public class AppConfigViewModel 7 | { 8 | public AppConfigurationOptions AppConfig { get; } 9 | public AppConfigViewModel(AppConfigurationOptions appConfig) 10 | { 11 | AppConfig = appConfig ?? new AppConfigurationOptions(); 12 | } 13 | } 14 | } 15 | 16 | // Lab01 - Lab04 End -------------------------------------------------------------------------------- /Lab01/CloudFoundry/ViewModels/SubSectionConfigViewModel.cs: -------------------------------------------------------------------------------- 1 | 2 | // Lab01 - Lab04 Start 3 | 4 | namespace CloudFoundry.ViewModels 5 | { 6 | public class SubSectionConfigViewModel 7 | { 8 | public SubSectionConfigurationOptions SubSectionConfig { get; } 9 | public SubSectionConfigViewModel(SubSectionConfigurationOptions sectionConfig) 10 | { 11 | SubSectionConfig = sectionConfig ?? new SubSectionConfigurationOptions(); 12 | } 13 | } 14 | } 15 | // Lab01 - Lab04 End -------------------------------------------------------------------------------- /Lab01/CloudFoundry/Views/Home/AppConfig.cshtml: -------------------------------------------------------------------------------- 1 | @model CloudFoundry.ViewModels.AppConfigViewModel 2 | @{ 3 | ViewBag.Title = "Application Configuration data from appsettings.json & appsettings.development.json"; 4 | } 5 |

@ViewBag.Title

6 | 7 |

Configuration Data

8 |

option1 = @Model.AppConfig.Option1

9 |

option2 = @Model.AppConfig.Option2

-------------------------------------------------------------------------------- /Lab01/CloudFoundry/Views/Home/RawConfig.cshtml: -------------------------------------------------------------------------------- 1 | @model Microsoft.Extensions.Configuration.IConfigurationRoot 2 | @using Microsoft.Extensions.Configuration 3 | 4 | @{ 5 | ViewBag.Title = "Raw Application Configuration data from appsettings.json & appsettings.development.json"; 6 | } 7 |

@ViewBag.Title

8 | 9 |

Configuration Data

10 | @foreach (KeyValuePair pair in Model.AsEnumerable()) 11 | { 12 |

@pair.Key=@pair.Value

13 | 14 | } -------------------------------------------------------------------------------- /Lab01/CloudFoundry/Views/Home/SubSectionConfig.cshtml: -------------------------------------------------------------------------------- 1 | @model CloudFoundry.ViewModels.SubSectionConfigViewModel 2 | @{ 3 | ViewBag.Title = "Application Subsection Configuration data from appsettings.json & appsettings.development.json"; 4 | } 5 |

@ViewBag.Title

6 | 7 |

Configuration Data

8 |

suboption1 = @Model.SubSectionConfig.Suboption1

9 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using CloudFoundry 2 | @using CloudFoundry.ViewModels 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | @addTagHelper *, CloudFoundry -------------------------------------------------------------------------------- /Lab01/CloudFoundry/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Debug", 6 | "System": "Information", 7 | "Microsoft": "Information" 8 | } 9 | }, 10 | "option1": "value1_from_appsettings_json", 11 | "option2": 2, 12 | 13 | "subsection": { 14 | "suboption1": "subvalue1_from_appsettings_json" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "LogLevel": { 5 | "Default": "Warning" 6 | } 7 | }, 8 | "option1": "value1_from_appsettings_json", 9 | "option2": 2, 10 | 11 | "subsection": { 12 | "suboption1": "subvalue1_from_appsettings_json" 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: env 4 | random-route: true 5 | stack: windows2012R2 6 | memory: 512M 7 | instances: 1 8 | buildpack: binary_buildpack 9 | command: cmd /c .\CloudFoundry --server.urls http://0.0.0.0:%PORT% 10 | env: 11 | ASPNETCORE_ENVIRONMENT: production -------------------------------------------------------------------------------- /Lab01/CloudFoundry/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: env 4 | memory: 512M 5 | stack: cflinuxfs2 6 | buildpack: dotnet_core_buildpack 7 | instances: 1 8 | random-route: true 9 | env: 10 | ASPNETCORE_ENVIRONMENT: production -------------------------------------------------------------------------------- /Lab01/CloudFoundry/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab01/CloudFoundry/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab01/CloudFoundry/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab01/CloudFoundry/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab01/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/Fortune-Teller-Service.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.0 5 | Fortune_Teller_Service 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information", 7 | "Fortune_Teller_Service": "Debug", 8 | "Steeltoe": "Debug", 9 | "Pivotal": "Debug" 10 | } 11 | }, 12 | "Console": { 13 | "LogLevel": { 14 | "Default": "Information", 15 | "Fortune_Teller_Service": "Debug", 16 | "Steeltoe": "Debug", 17 | "Pivotal": "Debug" 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information" 7 | } 8 | }, 9 | "Console": { 10 | "LogLevel": { 11 | "Default": "Information" 12 | } 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Fortune-Teller-UI.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.0 5 | Fortune_Teller_UI 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information", 7 | "Fortune_Teller_UI": "Debug", 8 | "Steeltoe": "Debug", 9 | "Pivotal": "Debug" 10 | } 11 | }, 12 | "Console": { 13 | "LogLevel": { 14 | "Default": "Information", 15 | "Fortune_Teller_UI": "Debug", 16 | "Steeltoe": "Debug", 17 | "Pivotal": "Debug" 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information" 7 | } 8 | }, 9 | "Console": { 10 | "LogLevel": { 11 | "Default": "Information" 12 | } 13 | } 14 | }, 15 | "fortuneService": { 16 | "scheme": "http", 17 | "address": "localhost:5000", 18 | "randomFortunePath": "api/fortunes/random", 19 | "allFortunesPath": "api/fortunes/all" 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Development 11 | 12 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Development 8 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab05/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab05/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab05/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab05/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab05/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab05/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab05/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab05/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | 14 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab06/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab06/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab06/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab06/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Lab06/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information -------------------------------------------------------------------------------- /Lab06/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /Lab06/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | fortuneService: 2 | scheme: http 3 | address: localhost:5000 4 | randomFortunePath: api/fortunes/random 5 | allFortunesPath: api/fortunes/all 6 | 7 | -------------------------------------------------------------------------------- /Lab06/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab06/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab06/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab06/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab06/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab06/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | } 3 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | 15 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab07/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab07/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab07/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab07/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Lab07/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information 9 | eureka: 10 | client: 11 | serviceUrl: http://localhost:8761/eureka/ 12 | validate_certificates: false -------------------------------------------------------------------------------- /Lab07/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldFetchRegistry: false 4 | instance: 5 | port: 5000 6 | -------------------------------------------------------------------------------- /Lab07/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldRegisterWithEureka: false 4 | fortuneService: 5 | scheme: http 6 | address: fortuneservice 7 | randomFortunePath: api/fortunes/random 8 | allFortunesPath: api/fortunes/all -------------------------------------------------------------------------------- /Lab07/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab07/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab07/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab07/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab07/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab07/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | } 3 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | 15 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myMySqlService -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myMySqlService 12 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myRedisService -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myRedisService 12 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab08/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab08/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab08/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab08/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Lab08/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information 9 | eureka: 10 | client: 11 | serviceUrl: http://localhost:8761/eureka/ 12 | validate_certificates: false -------------------------------------------------------------------------------- /Lab08/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldFetchRegistry: false 4 | instance: 5 | port: 5000 6 | mysql: 7 | client: 8 | database: mydatabase 9 | username: username 10 | password: password -------------------------------------------------------------------------------- /Lab08/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldRegisterWithEureka: false 4 | fortuneService: 5 | scheme: http 6 | address: fortuneservice 7 | randomFortunePath: api/fortunes/random 8 | allFortunesPath: api/fortunes/all -------------------------------------------------------------------------------- /Lab08/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab08/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab08/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab08/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab08/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab08/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | } 3 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | 15 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myMySqlService -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myMySqlService -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | 15 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myRedisService 15 | - myHystrixService -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myRedisService 12 | - myHystrixService 13 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab09/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab09/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab09/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab09/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Lab09/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information 9 | eureka: 10 | client: 11 | serviceUrl: http://localhost:8761/eureka/ 12 | validate_certificates: false 13 | security: 14 | oauth2: 15 | client: 16 | validate_certificates: false -------------------------------------------------------------------------------- /Lab09/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldFetchRegistry: false 4 | instance: 5 | port: 5000 6 | mysql: 7 | client: 8 | database: mydatabase 9 | username: username 10 | password: password -------------------------------------------------------------------------------- /Lab09/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldRegisterWithEureka: false 4 | hystrix: 5 | stream: 6 | validate_certificates: false 7 | fortuneService: 8 | scheme: http 9 | address: fortuneservice 10 | randomFortunePath: api/fortunes/random 11 | allFortunesPath: api/fortunes/all -------------------------------------------------------------------------------- /Lab09/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab09/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab09/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab09/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab09/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab09/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | } 3 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | 15 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myMySqlService 15 | - myOAuthService -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myMySqlService 12 | - myOAuthService 13 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | 15 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myRedisService 15 | - myHystrixService 16 | - myOAuthService -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myRedisService 12 | - myHystrixService 13 | - myOAuthService -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab10/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab10/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab10/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab10/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Lab10/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information 9 | eureka: 10 | client: 11 | serviceUrl: http://localhost:8761/eureka/ 12 | validate_certificates: false 13 | security: 14 | oauth2: 15 | client: 16 | validate_certificates: false -------------------------------------------------------------------------------- /Lab10/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldFetchRegistry: false 4 | instance: 5 | port: 5000 6 | mysql: 7 | client: 8 | database: mydatabase 9 | username: username 10 | password: password -------------------------------------------------------------------------------- /Lab10/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldRegisterWithEureka: false 4 | hystrix: 5 | stream: 6 | validate_certificates: false 7 | fortuneService: 8 | scheme: http 9 | address: fortuneservice 10 | randomFortunePath: api/fortunes/random 11 | allFortunesPath: api/fortunes/all -------------------------------------------------------------------------------- /Lab10/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab10/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab10/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab10/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab10/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab10/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | } 3 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneService" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/git.properties: -------------------------------------------------------------------------------- 1 | git.remote.origin.url=C:/workspace/Workshop 2 | git.build.version=0.1.0 3 | git.commit.id.abbrev=a4074a5 4 | git.commit.id=a4074a5422def25cb05070afc8da4cc77993d56c 5 | git.tags= 6 | git.branch=2.0 7 | git.build.time=2017-11-15T16:27:20.4013634-07:00 8 | git.build.user.name=dtillman 9 | git.build.host=DESKTOP-D0GL5GA 10 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myMySqlService 15 | - myOAuthService -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myMySqlService 12 | - myOAuthService 13 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | 3 | } 4 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "spring": { 3 | "application": { 4 | "name": "fortuneui" 5 | }, 6 | "cloud": { 7 | "config": { 8 | "uri": "http://localhost:8888", 9 | "validate_certificates": false 10 | } 11 | } 12 | } 13 | } 14 | 15 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/git.properties: -------------------------------------------------------------------------------- 1 | git.remote.origin.url=C:/workspace/Workshop 2 | git.build.version=0.1.0 3 | git.commit.id.abbrev=a4074a5 4 | git.commit.id=a4074a5422def25cb05070afc8da4cc77993d56c 5 | git.tags= 6 | git.branch=2.0 7 | git.build.time=2017-11-15T16:27:46.0130173-07:00 8 | git.build.user.name=dtillman 9 | git.build.host=DESKTOP-D0GL5GA 10 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | services: 12 | - myConfigServer 13 | - myDiscoveryService 14 | - myRedisService 15 | - myHystrixService 16 | - myOAuthService -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | services: 9 | - myConfigServer 10 | - myDiscoveryService 11 | - myRedisService 12 | - myHystrixService 13 | - myOAuthService -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab11/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab11/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Lab11/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Lab11/config-repo/application-Development.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Fortune_Teller_Service: Debug 7 | Fortune_Teller_UI: Debug 8 | Pivotal: Debug 9 | Steeltoe: Debug 10 | Console: 11 | LogLevel: 12 | Default: Information 13 | Fortune_Teller_Service: Debug 14 | Fortune_Teller_UI: Debug 15 | Pivotal: Debug 16 | Steeltoe: Debug -------------------------------------------------------------------------------- /Lab11/config-repo/application.yml: -------------------------------------------------------------------------------- 1 | Logging: 2 | IncludeScopes: false 3 | Debug: 4 | LogLevel: 5 | Default: Information 6 | Console: 7 | LogLevel: 8 | Default: Information 9 | eureka: 10 | client: 11 | serviceUrl: http://localhost:8761/eureka/ 12 | validate_certificates: false 13 | security: 14 | oauth2: 15 | client: 16 | validate_certificates: false 17 | management: 18 | endpoints: 19 | path: /cloudfoundryapplication 20 | cloudfoundry: 21 | validateCertificates: false -------------------------------------------------------------------------------- /Lab11/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldFetchRegistry: false 4 | instance: 5 | port: 5000 6 | mysql: 7 | client: 8 | database: mydatabase 9 | username: username 10 | password: password -------------------------------------------------------------------------------- /Lab11/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | eureka: 2 | client: 3 | shouldRegisterWithEureka: false 4 | hystrix: 5 | stream: 6 | validate_certificates: false 7 | fortuneService: 8 | scheme: http 9 | address: fortuneservice 10 | randomFortunePath: api/fortunes/random 11 | allFortunesPath: api/fortunes/all -------------------------------------------------------------------------------- /Lab11/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab11/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Lab11/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Lab11/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Lab11/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Lab11/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService -------------------------------------------------------------------------------- /Slides/Workshop.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Slides/Workshop.pdf -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/Fortune-Teller-Service.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.0 5 | Fortune_Teller_Service 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/Models/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_Service.Models 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/Models/FortuneContext.cs: -------------------------------------------------------------------------------- 1 | using Microsoft.EntityFrameworkCore; 2 | 3 | 4 | namespace Fortune_Teller_Service.Models 5 | { 6 | public class FortuneContext : DbContext 7 | { 8 | public FortuneContext(DbContextOptions options) : 9 | base(options) 10 | { 11 | 12 | } 13 | public DbSet Fortunes { get; set; } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/Models/FortuneEntity.cs: -------------------------------------------------------------------------------- 1 |  2 | namespace Fortune_Teller_Service.Models 3 | { 4 | public class FortuneEntity 5 | { 6 | public int Id { get; set; } 7 | public string Text { get; set; } 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/Models/IFortuneRepository.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Threading.Tasks; 5 | 6 | namespace Fortune_Teller_Service.Models 7 | { 8 | public interface IFortuneRepository 9 | { 10 | Task> GetAllAsync(); 11 | 12 | Task RandomFortuneAsync(); 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information" 7 | } 8 | }, 9 | "Console": { 10 | "LogLevel": { 11 | "Default": "Information" 12 | } 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information" 7 | } 8 | }, 9 | "Console": { 10 | "LogLevel": { 11 | "Default": "Information" 12 | } 13 | } 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-Service --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneService 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-Service/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "wwwroot/lib" 3 | } 4 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Fortune-Teller-UI.csproj: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | netcoreapp2.0 5 | Fortune_Teller_UI 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Models/ErrorViewModel.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Models 4 | { 5 | public class ErrorViewModel 6 | { 7 | public string RequestId { get; set; } 8 | 9 | public bool ShowRequestId => !string.IsNullOrEmpty(RequestId); 10 | } 11 | } -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Services/Fortune.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | 3 | namespace Fortune_Teller_UI.Services 4 | { 5 | public class Fortune 6 | { 7 | public int Id { get; set; } 8 | public string Text { get; set; } 9 | public override string ToString() 10 | { 11 | return $"Fortune[{this.Id},{this.Text}]"; 12 | } 13 | 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Services/IFortuneService.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Threading.Tasks; 3 | 4 | namespace Fortune_Teller_UI.Services 5 | { 6 | public interface IFortuneService 7 | { 8 | Task> AllFortunesAsync(); 9 | Task RandomFortuneAsync(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Views/Fortunes/AccessDenied.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Access Denied"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Views/Fortunes/Manage.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | ViewData["Title"] = "Manage Account"; 3 | } 4 |

@ViewData["Title"].

5 |

@ViewData["Message"]

-------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Views/Fortunes/RandomFortune.cshtml: -------------------------------------------------------------------------------- 1 | @model Fortune_Teller_UI.Services.Fortune 2 | @{ 3 | ViewData["Title"] = "Your Fortune"; 4 | } 5 |

@ViewData["Title"]

6 |

@Model.Text

7 | 8 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Views/_ViewImports.cshtml: -------------------------------------------------------------------------------- 1 | @using Fortune_Teller_UI 2 | @using Fortune_Teller_UI.Models 3 | @addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers 4 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "_Layout"; 3 | } 4 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/appsettings.Development.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information", 7 | "Fortune_Teller_UI": "Debug", 8 | "Steeltoe": "Debug", 9 | "Pivotal": "Debug" 10 | } 11 | }, 12 | "Console": { 13 | "LogLevel": { 14 | "Default": "Information", 15 | "Fortune_Teller_UI": "Debug", 16 | "Steeltoe": "Debug", 17 | "Pivotal": "Debug" 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/appsettings.json: -------------------------------------------------------------------------------- 1 | { 2 | "Logging": { 3 | "IncludeScopes": false, 4 | "Debug": { 5 | "LogLevel": { 6 | "Default": "Information" 7 | } 8 | }, 9 | "Console": { 10 | "LogLevel": { 11 | "Default": "Information" 12 | } 13 | } 14 | } 15 | 16 | } 17 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "asp.net", 3 | "private": true, 4 | "dependencies": { 5 | "bootstrap": "3.3.7", 6 | "jquery": "2.2.0", 7 | "jquery-validation": "1.14.0", 8 | "jquery-validation-unobtrusive": "3.2.6" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/bundleconfig.json: -------------------------------------------------------------------------------- 1 | // Configure bundling and minification for the project. 2 | // More info at https://go.microsoft.com/fwlink/?LinkId=808241 3 | [ 4 | { 5 | "outputFileName": "wwwroot/css/site.min.css", 6 | // An array of relative input file paths. Globbing patterns supported 7 | "inputFiles": [ 8 | "wwwroot/css/site.css" 9 | ] 10 | }, 11 | { 12 | "outputFileName": "wwwroot/js/site.min.js", 13 | "inputFiles": [ 14 | "wwwroot/js/site.js" 15 | ], 16 | // Optionally specify minification options 17 | "minify": { 18 | "enabled": true, 19 | "renameLocals": true 20 | }, 21 | // Optionally generate .map file 22 | "sourceMap": false 23 | } 24 | ] 25 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/manifest-windows.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: binary_buildpack 6 | memory: 512M 7 | stack: windows2012R2 8 | command: cmd /c .\Fortune-Teller-UI --server.urls http://*:%PORT% 9 | env: 10 | ASPNETCORE_ENVIRONMENT: Production 11 | 12 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/manifest.yml: -------------------------------------------------------------------------------- 1 | --- 2 | applications: 3 | - name: fortuneui 4 | random-route: true 5 | buildpack: dotnet_core_buildpack 6 | env: 7 | ASPNETCORE_ENVIRONMENT: Production 8 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/css/site.min.css: -------------------------------------------------------------------------------- 1 | body{padding-top:50px;padding-bottom:20px}.body-content{padding-left:15px;padding-right:15px}.carousel-caption p{font-size:20px;line-height:1.4}.carousel-inner .item img[src$=".svg"]{width:100%}#qrCode{margin:15px}@media screen and (max-width:767px){.carousel-caption{display:none}} -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/Fortune-Teller-UI/wwwroot/favicon.ico -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/js/site.js: -------------------------------------------------------------------------------- 1 | // Write your JavaScript code. 2 | -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/js/site.min.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/Fortune-Teller-UI/wwwroot/js/site.min.js -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/fonts/glyphicons-halflings-regular.woff2 -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/lib/bootstrap/dist/js/npm.js: -------------------------------------------------------------------------------- 1 | // This file is autogenerated via the `commonjs` Grunt task. You can require() this file in a CommonJS environment. 2 | require('../../js/transition.js') 3 | require('../../js/alert.js') 4 | require('../../js/button.js') 5 | require('../../js/carousel.js') 6 | require('../../js/collapse.js') 7 | require('../../js/dropdown.js') 8 | require('../../js/modal.js') 9 | require('../../js/tooltip.js') 10 | require('../../js/popover.js') 11 | require('../../js/scrollspy.js') 12 | require('../../js/tab.js') 13 | require('../../js/affix.js') -------------------------------------------------------------------------------- /Start/Fortune-Teller-UI/wwwroot/lib/jquery/.bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "jquery", 3 | "main": "dist/jquery.js", 4 | "license": "MIT", 5 | "ignore": [ 6 | "package.json" 7 | ], 8 | "keywords": [ 9 | "jquery", 10 | "javascript", 11 | "browser", 12 | "library" 13 | ], 14 | "homepage": "https://github.com/jquery/jquery-dist", 15 | "version": "2.2.0", 16 | "_release": "2.2.0", 17 | "_resolution": { 18 | "type": "version", 19 | "tag": "2.2.0", 20 | "commit": "6fc01e29bdad0964f62ef56d01297039cdcadbe5" 21 | }, 22 | "_source": "git://github.com/jquery/jquery-dist.git", 23 | "_target": "2.2.0", 24 | "_originalSource": "jquery" 25 | } -------------------------------------------------------------------------------- /Start/README.md: -------------------------------------------------------------------------------- 1 | # Workshop Starting Code 2 | 3 | Here you will find the code you should start with when doing Lab5 through Lab11. -------------------------------------------------------------------------------- /Start/config-repo/application-Development.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/config-repo/application-Development.yml -------------------------------------------------------------------------------- /Start/config-repo/application.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vmware-archive/Workshop/d5145b00d8c20788766ca5fd9eb85b799df68017/Start/config-repo/application.yml -------------------------------------------------------------------------------- /Start/config-repo/fortuneService.yml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /Start/config-repo/fortuneui.yml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /Start/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git" : { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Start/nuget.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /Start/scripts/config-server.json: -------------------------------------------------------------------------------- 1 | { 2 | "git": { 3 | "uri": "https://github.com/SteeltoeOSS/workshop-config-repo" 4 | } 5 | } -------------------------------------------------------------------------------- /Start/scripts/createCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf create-service p-config-server standard myConfigServer -c config-server.json 4 | cf create-service p-service-registry standard myDiscoveryService 5 | cf create-service p-mysql 100mb myMySqlService 6 | cf create-service p-redis shared-vm myRedisService 7 | cf create-service p-circuit-breaker-dashboard standard myHystrixService 8 | cf cups myOAuthService -p "{\"client_id\": \"myTestApp\",\"client_secret\": \"myTestApp\",\"uri\": \"uaa://login.system.testcloud.com\"}" 9 | -------------------------------------------------------------------------------- /Start/scripts/deleteCloudFoundryServices.cmd: -------------------------------------------------------------------------------- 1 | @ECHO OFF 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService 9 | -------------------------------------------------------------------------------- /Start/scripts/deleteCloudFoundryServices.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | cf delete-service myConfigServer 4 | cf delete-service myDiscoveryService 5 | cf delete-service myMySqlService 6 | cf delete-service myRedisService 7 | cf delete-service myHystrixService 8 | cf delete-service myOAuthService --------------------------------------------------------------------------------