ТЕМА: Fort Worth : devops pptx - Kabrinskiy Eduard

Fort Worth : devops pptx - Kabrinskiy Eduard 2 років 10 місяців тому #30082

Kabrinskiy Eduard - Ibm continuous delivery - Kabrinskiy Eduard


<h1>Ibm continuous delivery</h1>
<p>[youtube]</p>
Ibm continuous delivery <a href="remmont.com">Live news</a> Ibm continuous delivery
<h1>Ibm continuous delivery</h1>
<p>Spring Boot on Bluemix with IBM Continuous Delivery</h1></p>
<p>The goal of this lab is to demonstrate deploying a simple Java web application to Bluemix with a DevOps pipeline for managing the application lifecycle.</p>
<p>As part of this deployment, several actions are happening automatically through the use of configuration files found in the .bluemix folder. The two primary actions that are automatically configured to occur are deploying two different microservices from two different repositories and integrating multiple Bluemix services into the deployed applications.</p>
<p>Table of Contents</h2></p>
<p>A Bluemix account is required to complete this lab.</p>
<p>To sign up for a new account visit Bluemix.net</p>
<p>A Slack team is an <strong>optional</strong> requirement to complete this lab.</p>
<p>To sign up for a new team visit slack.com</p>
<p>Log into the Bluemix console and create a Cloudant instance named sample-java-cloudant-cloudantNoSQLDB .</p>
<p>Click the following Deploy to Bluemix button to load the initial toolchain setup:</p>
<p> </p>
<p>Once the Tool Integrations have loaded, click on each of the four different integrations to see what settings are available to be changed.</p>
<p><strong>Note:</strong> that the fields for GitHub, Eclipse Orion Web IDE, and Delivery Pipeline are automatically populated with data and no input should be required by the user unless changes to what was populated are desired.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...ToolIntegrations.png" /> </p>
<p><strong>Optional:</strong> Slack Integration. Skip to Step 4 if you choose not to configure it.</p>
<p>Slack Integration allows your team to be notified of events occuring in your Delivery Pipeline. To configure this integration, create an incoming webhook for your Slack team using the Slack API. Once created, fill in the three fields listed under the Slack Integration.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...SlackIntegration.png" /></p>
<p>Click the "Create" button in the bottom right area of the window to instruct Bluemix to create a toolchain for you using the defined settings.</p>
<p> </p>
<p>The page that loads after clicking create is the application's Toolchain. Here is the overview of all of the integrated services, the flow of the project, and easy navigation to each of the individual components of the application.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...ervicesToolchain.png" /> </p>
<p><strong>Note:</strong> In this view, Slack was not configured in the previous step before clicking "Create". Slack can be configured at any time after creation of the Toolchain.</p>
<p>As soon as the "Create" button was pressed, Bluemix went to work deploying the application via the defined pipeline configurations. Click on the "Delivery Pipeline" box that starts with the words "spring-boot-continuous. " (shown below) in the Toolchain to view the code deployment pipeline of our primary application.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...DeliveryPipeline.png" /></p>
<p>The pipeline page will dynamically update with the status of each step in the pipeline. When the deployment has finished running the bar on the top of the "Deploy Stage" will turn green.</p>

</ol>
<table><thead><tr><th align="center">In Progress</th><th align="center">Finished</th></tr></th><tbody><tr><td align="center"><img src="github.com/IBM/spring-boot-continuous-de...pelineInProgress.png" /></td><td align="center"><img src="github.com/IBM/spring-boot-continuous-de...PipelineFinished.png" /></td></tr></tbody></table><ol>
<p>Once the "Deploy Stage" has turned green, indicating the job is complete, the link to the deployed application can be found in the mid-section of the "Deploy Stage" card.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de.../PipelineAppLink.png" /></p>
<p>Upon clicking the application's URL, a new tab will open to the application's main page.</p>
<p>
</ol>
<table><thead><tr><th align="center">Create a New Account</th><th align="center">Account Created</th></tr></th><tbody><tr><td align="center"><img src="github.com/IBM/spring-boot-continuous-de...ia/AccountImage1.png" /></td><td align="center"><img src="github.com/IBM/spring-boot-continuous-de...ia/AccountImage2.png" /></td></tr></tbody></table></p>
<p>Admin Dashboard Microservice</h3></p>
<p>Return to the Toolchain page and click on the other pipeline that has not yet been viewed ("admin-spring-boot. ").</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...ia/AdminPipeline.png" /></p>
<p>Once the pipeline page has loaded a similar set of deployment steps to our primary microservice can be found. Once the deployment has completed, click on the url listed in the middle of the "Deploy Stage" card. The URL will look similar to the one shown below.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de.../adminUrlExample.png" /></p>
<p>After the application's webpage has loaded a simulated admin dashboard will show the names and account ids created from the other microservice's webpage. The admin and main application are both communicating with the same Cloudant DB instance in the backend but have no direct communication between each other.</p>
<p>
</ol>
<table><thead><tr><th align="center">Full Account List</th><th align="center">Searching Accounts</th></tr></th><tbody><tr><td align="center"><img src="github.com/IBM/spring-boot-continuous-de.../media/AdminApp1.png" /></td><td align="center"><img src="github.com/IBM/spring-boot-continuous-de.../media/AdminApp2.png" /></td></tr></tbody></table></p>
<p>The following steps will show how to access the account that was just created in the Cloudant DB database</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...dia/FindService2.png" /></p>
<p>Once on the Services Dashboard, locate your Cloudant DB and click on it to open the service description page.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...dia/FindService3.png" /></p>
<p>Click on the "LAUNCH" button near the top right of the page to load into the Cloudant DB dashboard.</p>
<p>Once the Cloudant DB dashboard has finished loading, select the databases tab on the left.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...er/media/OpenDB2.png" /></p>
<p>Click on the "Account" database. On the right you will see the account that was created from the web app above.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...r/media/DBEntry1.png" /></p>
<p>Click on the database entry to view more details.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...r/media/DBEntry2.png" />
</ol>
</p>
<p>Updating Individual Microservices</h1></p>
<p>One of the great things about how Toolchains can be configured is that it can have multiple stand alone pipelines and code repositories. The way this Toolchain has been configured sets up two independent GitHub repositories and then two independent delivery pipelines. What that means is if you commit a change to one repository it will deploy that change automatically into its associated pipeline but the other repository and pipeline will be completely unaffected.</p>
<p>To demonstrate this, choose either of the two GitHub repositories to edit. For our demonstration, we are going to edit the main application's code. For simplicity, we're going to edit the index.jps file via the GitHub web interface.</p>
<p>Navigate to your cloned version of the project on GitHub.com.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...media/ClonedRepo.png" /></p>
<p>Navigate to the index.jsp file: src -> main -> webapp -> index.jsp</p>
<p><strong>Note:</strong> The above example URL will be different depending on your GitHub username and the string of numbers assigned to your cloned version of the application.</p>
<p>Open the index.jsp file for editing:</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de.../media/EditIndex.png" /></p>
<p>Change the application's header to "Create a new account. Edited!". See the following for reference:</p>
<p>Save and commit the change to your index.jsp</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...media/CommitFile.png" /></p>
<p>Return to your deployment pipelines to view the deployment progress. The application may deploy quickly, if it is done deploying before you can navigate back to it you can view recent deployment logs to verify that only the primary application was deployed with the recent commit. Click here to navigate back to the Toolchain overview dashboard.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...pelineUnaffected.png" /></p>
<p>Finally, open the primary application's webpage again to view the recently committed change.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...ia/WebpageEdited.png" />
</ol>
</p>
<p>In this application we use several different files that each server an important part of customizing our Bluemix deployment. Below we will give a brief overview of each file's function.</p>
<p>The toolchain.yml file is used to define the desired application name, integrated services, descriptions, environment properties, and more. This file is what pulls in the pipeline.yml, deploy.json, and custom Toolchain image used in this application.</p>
<p>For our application we have integrated GitHub as a code repository as well as for issue tracking, Eclipse Orian Web IDE for editing code via the web interface, and a pipeline to deploy the application from the integrated GitHub repository.</p>
<p>The deploy.json file is what allows user customization of the Toolchain via the UI before the user clicks deploy but after the user has clicked the "Deploy to Bluemix" button from the GitHub repository.</p>
<p>For our application we have configured the deploy.son file to capture and require three fields that will be used as environment variables by the toolchain.yml: selected-region, selected-organization, and selected-space. We have created a three column form that allows users to select fields for each of the afore mentioned variables if the defaults are not desired. Finally, we have called a helper function to validate the input variables.</p>
<p>The pipeline.yml file is used to configure the Bluemix Pipeline for an application. A toolchain can have multiple pipeline files. One way to rename the pipeline.yml files is to add a prefix to the pipeline.yml file's name: example-pipeline.yml. In the pipeline.yml file we can specify things such as build steps, environment variables, custom scripts and instructions, etc.</p>
<p>For our application we have configured the pipeline.yml to build our maven project to a custom location and then deploy the built .war file from the custom location. Additionally, in our pipeline.yml file we have specified the application memory limit using the cf command:</p>
<p>cf push "$<CF_APP>" -p "springboot-demo.war" -m 256M</p>
<p>One of the primary aspects of this lab is to demonstrate simplified deployment of microservices from multiple repositories. As part of the setup for the different microservices a unique deployment pipeline cis reated for and connected to each of the individual microservice's repositories. By creating a different pipeline for each repository we are enabling each service to have its code updated and re-deployed completely independent of the operation of the other microservice; that is to say, by having two pipelines we can update the code for one microservice and the other microservice will be completely unaffected and unaware anything happened.</p>
<p><strong>Note:</strong> No direct interaction with the associated repositories is required. All of the deployment interaction is done through the current repository.</p>
<p>Security Vulnerability Scanning</h1></p>
<p>Easily scan your web application for security vulnerabilites using the Application Security on Cloud service on Bluemix.</p>
<p>From the Bluemix Catalog click <strong>Security</strong> from the left-side menu, or simply search for <strong>Application Security on Cloud</strong> in the search prompt.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...SecurityServices.png" /></p>
<p>Click on the <strong>Application Security on Cloud</strong> service.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...pSecurityOnCloud.png" /></p>
<p>Choose a service name, or keep the pre-populated name. Click <strong>Create</strong>.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...ppSecurityCreate.png" /></p>
<p>You will see three application options for scanning. Click <strong>Web</strong>.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...pSecurityWebScan.png" /></p>
<p>The next screen will ask you to choose a scan type. Click <strong>Dynamic</strong>.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...SecurityScanType.png" /></p>
<p>For site location choose <strong>Public Network</strong>.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...pSecurityNetwork.png" /></p>
<p>You will then be asked for a site URL. Enter you Bluemix application URL and click <strong>Continue</strong>.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...a/AppSecurityURL.png" /> </p>
<p><strong>Note</strong>: You may be required to add a verification file to ensure your application URL is valid. If this occurs, place the IBMDomainVerification.html file in the src/main/webapp/ directory of your cloned repo. Wait for the application to redeploy before scanning.</p>
<p>The next screen will contain various scan settings, leave these set to the defaults. Click <strong>Scan</strong>.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...rityScanSettings.png" /> </p>
<p>Your security vulnerability scan will start running.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...tyScanInProgress.png" /> </p>
<p>Once the scan is complete you will see the total number of vulnerabitites and the associated severity ratings.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...pSecurityResults.png" /></p>
<p>You can choose to download the detailed security report, and work to remediate the issues found.</p>
<p style="clear: both"><img src="github.com/IBM/spring-boot-continuous-de...ppSecurityReport.png" />
</ol>
</p>
<p>Deploying to Kubernetes</h1></p>
<p>One deployment option is to deploy this application to kubernetes. For this option, we will provision a lite kubernetes cluster via the IBM Bluemix Container Service and deploy the service using the manifests/deployment.yml file.</p>
<p>Provision and configure IBM Bluemix Container Service</h4></p>
<ol>
<li>Log into the Bluemix console and create a lite Kubernetes cluster named mycluster . This will take several minutes to provision.</li>
</ol>
<ol>
<li>Create a Cloudant instance (if you haven't already) named sample-java-cloudant-cloudantNoSQLDB .</li>
<li>Install kubectl. Kubectl is the standard way to interact with Kubernetes clusters. You will configure kubectl to point to your Kubernetes cluster hosted on the IBM Bluemix Container Service.</li>
<li>Download the IBM Bluemix CLI</li>
<li>Make sure you login, then install the IBM Bluemix Container Service plug-in.</li>
</ol>
<ol>
<li>List the clusters. You should see the cluster you created: mycluster . If you don't, make sure you have waited enough time for the cluster to be provisioned. You should see the cluster state as "Ready" in the Bluemix console.</li>
</ol>
<ol>
<li>Configure your kubectl to point to your Kubernetes cluster.</li>
</ol>
<p>This should give you an export KUBE_CONFIG line. Copy and paste this to configure your kubectl to point to your Kubernetes cluster. For example:</p>
<p><ol>
<li>Verify that your kubectl is configured. The following should show: mycluster .</li>
</ol>
</p>
<p>You can now send commands to your Kubernetes cluster!</p>
<p>Bind the Cloudant Service</h4></p>
<p>We will use the Bluemix CLI to create a binding between our Cloudant instance and our Kubernetes cluster.</p>
<ol>
<li>Bind the Cloudant service.</li>
</ol>
<p>The command above loads a Kubernetes secret into your cluster that contains information to connect to your Cloudant instance. The application is configured to read this secret when it is deployed.</p>
<p>Deploy the Application</h4></p>
<p>The manifests/deployment.yml contains the Kubernetes defition to deploy the application. Deploy the application.</p>
<p>Test the Application</h4></p>
<p>The deployment uses NodePort to expose the application on all nodes in the cluster. To access the application, first get IP of the worker node in the cluster.</p>
<p>Then lists the services to get the port for your application.</p>
<h2>About</h2>
<p>In this project we demonstrate how to deploy a simple Spring Boot application to Bluemix. Additionally, we demonstrate the basic files needed to deploy a project to Bluemix with a configured toolchain, pipeline, and service integrations.</p>
<h2>Ibm continuous delivery</h2>

<h3>Ibm continuous delivery</h3>
<p>[youtube]</p>
Ibm continuous delivery <a href="remmont.com">News stories</a> Ibm continuous delivery
<h4>Ibm continuous delivery</h4>
In this project we demonstrate how to deploy a simple Spring Boot application to Bluemix. Additionally, we demonstrate the basic files needed to deploy a project to Bluemix with a configured toolchain, pipeline, and service integrations. - IBM/spring-boot-continuous-delivery
<h5>Ibm continuous delivery</h5>
Ibm continuous delivery <a href="remmont.com">Ibm continuous delivery</a> Ibm continuous delivery
SOURCE: <h6>Ibm continuous delivery</h6> <a href="dev-ops.engineer/">Ibm continuous delivery</a> Ibm continuous delivery
#tags#[replace: -,-Ibm continuous delivery] Ibm continuous delivery#tags#

Eduard Kabrinskiy
news
  • EMMABoolo
  • EMMABoolo аватар
  • Немає на сайті
  • Платиновий учасник
  • Дописи: 1187
  • Репутація: 0
Адміністратор заборонив доступ на запис.
Час відкриття сторінки: 0.042 секунд