mirror of
https://github.com/openshift/openshift-docs.git
synced 2026-02-05 12:46:18 +01:00
OSDOCS#17254: CQA updates for the CLI tutorial
This commit is contained in:
committed by
openshift-cherrypick-robot
parent
04c0b6d903
commit
195d8c95a9
@@ -6,7 +6,8 @@
|
||||
[id="getting-started-cli-connecting-database_{context}"]
|
||||
= Deploying the database application
|
||||
|
||||
The following procedure deploys `mongodb-nationalparks`, which is a MongoDB database that will hold the national park location information.
|
||||
[role="_abstract"]
|
||||
Deploy a MongoDB database application to contain the information that your application requires. For this tutorial, you will deploy a database application called `mongodb-nationalparks` that holds the national park location information.
|
||||
|
||||
.Prerequisites
|
||||
|
||||
@@ -23,7 +24,6 @@ $ oc new-app registry.redhat.io/rhmap47/mongodb --name mongodb-nationalparks -e
|
||||
----
|
||||
+
|
||||
.Example output
|
||||
+
|
||||
[source,text]
|
||||
----
|
||||
--> Found container image 7a61087 (12 days old) from quay.io for "quay.io/mongodb/mongodb-enterprise-server"
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-creating-new-project_{context}"]
|
||||
= Creating a project
|
||||
|
||||
[role="_abstract"]
|
||||
Create a new project to contain all required resources and application components for the tutorial.
|
||||
|
||||
A _project_ enables a community of users to organize and manage their content in isolation. Projects are {product-title} extensions to Kubernetes namespaces. Projects have additional features that enable user self-provisioning. Each project has its own set of objects, policies, constraints, and service accounts.
|
||||
|
||||
Cluster administrators can allow developers to create their own projects. In most cases, you automatically have access to your own projects. Administrators can grant access to other projects as needed.
|
||||
|
||||
@@ -6,7 +6,8 @@
|
||||
[id="getting-started-cli-creating-route-backend_{context}"]
|
||||
= Exposing the back-end service
|
||||
|
||||
Similar to how you exposed the front-end service for external clients, you must now expose the back-end service by creating a route.
|
||||
[role="_abstract"]
|
||||
To expose the back-end service so that it is accessible externally, create a route.
|
||||
|
||||
.Prerequisites
|
||||
|
||||
|
||||
@@ -6,9 +6,10 @@
|
||||
[id="getting-started-cli-creating-route_{context}"]
|
||||
= Exposing the front-end service
|
||||
|
||||
By default, services running on {product-title} are not accessible externally.
|
||||
[role="_abstract"]
|
||||
By default, services running on {product-title} are not accessible externally. To expose your service so that external clients can access it, you can create a _route_.
|
||||
|
||||
To expose your service so that external clients can access it, you can create a _route_. A `Route` object is a {product-title} networking resource similar to a Kubernetes `Ingress` object. The default {product-title} router (HAProxy) uses the HTTP header of the incoming request to determine where to proxy the connection.
|
||||
A `Route` object is a {product-title} networking resource similar to a Kubernetes `Ingress` object. The default {product-title} router (HAProxy) uses the HTTP header of the incoming request to determine where to proxy the connection.
|
||||
|
||||
Optionally, you can define security, such as TLS, for the route.
|
||||
|
||||
@@ -37,7 +38,6 @@ $ oc get route parksmap
|
||||
----
|
||||
+
|
||||
.Example output
|
||||
+
|
||||
[source,terminal]
|
||||
----
|
||||
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-creating-secret_{context}"]
|
||||
= Providing access to the database by creating a secret
|
||||
|
||||
[role="_abstract"]
|
||||
Create a `Secret` resource to securely provide the back-end application with the sensitive database connection credentials.
|
||||
|
||||
The `nationalparks` application needs information, such as the database name, username, and passwords, to access the MongoDB database. However, because this information is sensitive, you should not store it directly in the pod.
|
||||
|
||||
You can use a _secret_ to store sensitive information, and share that secret with workloads.
|
||||
@@ -43,7 +46,6 @@ $ oc rollout status deployment nationalparks
|
||||
----
|
||||
+
|
||||
.Example output
|
||||
+
|
||||
[source,terminal]
|
||||
----
|
||||
deployment "nationalparks" successfully rolled out
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-deploying-first-image_{context}"]
|
||||
= Deploying the front-end application
|
||||
|
||||
[role="_abstract"]
|
||||
Deploy the front-end application that provides the external-facing web component for the tutorial.
|
||||
|
||||
The simplest way to deploy an application in {product-title} is to run a provided container image.
|
||||
|
||||
The following procedure deploys `parksmap`, which is the front-end component of the `national-parks-app` application. The web application displays an interactive map of the locations of national parks across the world.
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-deploying-python-app_{context}"]
|
||||
= Deploying the back-end application
|
||||
|
||||
[role="_abstract"]
|
||||
Deploy the back-end application that provides the service that queries the database to return the national park data required for your application.
|
||||
|
||||
The following procedure deploys `nationalparks`, which is the back-end component for the `national-parks-app` application. The Python application performs 2D geo-spatial queries against a MongoDB database to locate and return map coordinates of all national parks in the world.
|
||||
|
||||
.Prerequisites
|
||||
@@ -22,7 +25,6 @@ $ oc new-app python~https://github.com/openshift-roadshow/nationalparks-py.git -
|
||||
----
|
||||
+
|
||||
.Example output
|
||||
+
|
||||
[source,text]
|
||||
----
|
||||
--> Found image 9531750 (2 weeks old) in image stream "openshift/python" under tag "3.11-ubi8" for "python"
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-examining-pod_{context}"]
|
||||
= Viewing pod details
|
||||
|
||||
[role="_abstract"]
|
||||
Retrieve detailed pod information to confirm the running status and resource configuration of the applications in this tutorial.
|
||||
|
||||
{product-title} uses the Kubernetes concept of a _pod_, which is one or more containers deployed together on one host, and the smallest compute unit that can be defined, deployed, and managed.
|
||||
Pods are the rough equivalent of a machine instance, physical or virtual, to a container.
|
||||
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-granting-permissions_{context}"]
|
||||
= Granting view permissions
|
||||
|
||||
[role="_abstract"]
|
||||
Configure the necessary permissions for the application to access the required cluster resources.
|
||||
|
||||
{product-title} automatically creates several service accounts in every project. The `default` service account takes responsibility for running the pods. {product-title} uses and injects this service account into every pod that launches.
|
||||
|
||||
By default, the `default` service account has limited permissions to interact with the OpenShift API.
|
||||
|
||||
@@ -6,7 +6,8 @@
|
||||
[id="getting-started-cli-load-data-output_{context}"]
|
||||
= Loading data into the database
|
||||
|
||||
After you have deployed the `mongodb-nationalparks` database, you can load the national park location information into the database.
|
||||
[role="_abstract"]
|
||||
After you have deployed the `mongodb-nationalparks` database application, load the national park location information into the database.
|
||||
|
||||
.Prerequisites
|
||||
|
||||
@@ -23,7 +24,6 @@ $ oc exec $(oc get pods -l component=nationalparks | tail -n 1 | awk '{print $1;
|
||||
----
|
||||
+
|
||||
.Example output
|
||||
+
|
||||
[source,text]
|
||||
----
|
||||
"Items inserted in database: 2893"
|
||||
@@ -39,7 +39,6 @@ $ oc exec $(oc get pods -l component=nationalparks | tail -n 1 | awk '{print $1;
|
||||
----
|
||||
+
|
||||
.Example output (trimmed)
|
||||
+
|
||||
[source,terminal]
|
||||
----
|
||||
...
|
||||
|
||||
@@ -6,6 +6,9 @@
|
||||
[id="getting-started-cli-scaling-app_{context}"]
|
||||
= Scaling up the deployment
|
||||
|
||||
[role="_abstract"]
|
||||
Scale the application deployment up or down to meet workload demands.
|
||||
|
||||
In Kubernetes, a `Deployment` object defines how an application deploys. In most cases when you deploy an application, {product-title} creates the `Pod`, `Service`, `ReplicaSet`, and `Deployment` resources for you.
|
||||
|
||||
When you deploy the `parksmap` image, a deployment resource is created. In this example, only one pod is deployed. You might want to scale up your application to keep up with user demand or to ensure that your application is always running even if one pod is down.
|
||||
|
||||
@@ -6,9 +6,8 @@
|
||||
[id="getting-started-cli-view_{context}"]
|
||||
= Viewing the application in a web browser
|
||||
|
||||
After you have deployed the necessary applications and loaded data into the database, you are now ready view the national parks application through a browser.
|
||||
|
||||
You can get the URL for the application by retrieving the route information for the front-end application.
|
||||
[role="_abstract"]
|
||||
After you have deployed the necessary applications and loaded data into the database, you are now ready view your application through a browser. You can get the URL for the application by retrieving the route information for the front-end application.
|
||||
|
||||
.Prerequisites
|
||||
|
||||
@@ -27,7 +26,6 @@ $ oc get route parksmap
|
||||
----
|
||||
+
|
||||
.Example output
|
||||
+
|
||||
[source,terminal]
|
||||
----
|
||||
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD
|
||||
|
||||
@@ -6,7 +6,8 @@ include::_attributes/common-attributes.adoc[]
|
||||
|
||||
toc::[]
|
||||
|
||||
This tutorial guides you through deploying services to stand up an application called `national-parks-app` on {product-title} that displays a map of national parks across the world. You will use the {oc-first} to complete this tutorial.
|
||||
[role="_abstract"]
|
||||
To learn how to stand up an application on {product-title} by using the {oc-first}, follow the provided tutorial. In this tutorial, you will deploy the services that are required for an application that displays a map of national parks across the world.
|
||||
|
||||
To complete this tutorial, you will perform the following steps:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user