:_mod-docs-content-type: ASSEMBLY
[id="dev-app-web-console"]
= Tutorial: Deploying an application by using the web console
include::_attributes/common-attributes.adoc[]
:context: dev-app-web-console

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 {product-title} web console to complete this tutorial.

To complete this tutorial, you will perform the following steps:

. xref:../tutorials/dev-app-web-console.adoc#getting-started-web-console-creating-new-project_dev-app-web-console[Create a project for the application].
+
This step allows your application to be isolated from other cluster user's workloads.

. xref:../tutorials/dev-app-web-console.adoc#getting-started-web-console-granting-permissions_dev-app-web-console[Grant view permissions].
+
This step grants `view` permissions to interact with the OpenShift API to help discover services and other resources running within the project.

. xref:../tutorials/dev-app-web-console.adoc#getting-started-web-console-deploying-first-image_dev-app-web-console[Deploy the front-end application].
+
This step deploys the `parksmap` front-end application, exposes it externally, and scales it up to two instances.

. xref:../tutorials/dev-app-web-console.adoc#getting-started-web-console-deploying-python-app_dev-app-web-console[Deploy the back-end application].
+
This step deploys the `nationalparks` back-end application and exposes it externally.

. xref:../tutorials/dev-app-web-console.adoc#getting-started-web-console-connecting-database_dev-app-web-console[Deploy the database application].
+
This step deploys the `mongodb-nationalparks` MongoDB database, loads data into the database, and sets up the necessary credentials to access the database.

After you complete these steps, you can xref:../tutorials/dev-app-web-console.adoc#getting-started-web-console-view_dev-app-web-console[view the national parks application in a web browser].

[id="prerequisites_{context}"]
== Prerequisites

Before you start this tutorial, ensure that you have the following required prerequisites:

* You have access to a test {product-title} cluster.
+
If your organization does not have a cluster to test on, you can request access to the link:https://developers.redhat.com/developer-sandbox[Developer Sandbox] to get a trial of {product-title}.

* You have the appropriate permissions, such as the `cluster-admin` xref:../authentication/using-rbac.adoc#viewing-cluster-roles_using-rbac[cluster role], to create a project and applications within it.
+
If you do not have the required permissions, contact your cluster administrator. You need the `self-provisioner` role to create a project and the `admin` role on the project to modify resources in that project.
+
If you are using Developer Sandbox, a project is created for you with the required permissions.

* You have xref:../web_console/web-console.adoc#web-console-overview[logged in to the {product-title} web console].

// Creating a new project
include::modules/getting-started-web-console-creating-new-project.adoc[leveloffset=+1]

[role="_additional-resources"]
.Additional resources
* xref:../applications/projects/working-with-projects.adoc#viewing-a-project-using-the-web-console_projects[Viewing a project by using the web console]

// Granting view permissions
include::modules/getting-started-web-console-granting-permissions.adoc[leveloffset=+1]

[role="_additional-resources"]
.Additional resources
* xref:../authentication/using-rbac.adoc#authorization-overview_using-rbac[RBAC overview]

// Deploying the front-end application
include::modules/getting-started-web-console-deploying-first-image.adoc[leveloffset=+1]

[role="_additional-resources"]
.Additional resources
* xref:../applications/odc-viewing-application-composition-using-topology-view.adoc#odc-viewing-application-topology_viewing-application-composition-using-topology-view[Viewing the topology of your application]

// Viewing pod details
include::modules/getting-started-web-console-examining-pod.adoc[leveloffset=+2]

[role="_additional-resources"]
.Additional resources
* xref:../applications/odc-viewing-application-composition-using-topology-view.adoc#odc-interacting-with-applications-and-components_viewing-application-composition-using-topology-view[Interacting with applications and components]
* xref:../applications/odc-viewing-application-composition-using-topology-view.adoc#odc-scaling-application-pods-and-checking-builds-and-routes_viewing-application-composition-using-topology-view[Scaling application pods and checking builds and routes]
* xref:../applications/odc-viewing-application-composition-using-topology-view.adoc#odc-labels-and-annotations-used-for-topology-view_viewing-application-composition-using-topology-view[Labels and annotations used for the Topology view]

// Scaling up the deployment
include::modules/getting-started-web-console-scaling-app.adoc[leveloffset=+2]

[role="_additional-resources"]
.Additional resources
* xref:../scalability_and_performance/recommended-performance-scale-practices/recommended-control-plane-practices.adoc#recommended-scale-practices_recommended-control-plane-practices[Recommended practices for scaling the cluster]

// Deploying the back-end application
include::modules/getting-started-web-console-deploying-python-app.adoc[leveloffset=+1]

[role="_additional-resources"]
.Additional resources
* xref:../applications/odc-viewing-application-composition-using-topology-view.adoc#odc-adding-services-to-your-application_viewing-application-composition-using-topology-view[Adding services to your application]
* xref:../applications/creating_applications/odc-creating-applications-using-developer-perspective.adoc#odc-importing-codebase-from-git-to-create-application_odc-creating-applications-using-developer-perspective[Importing a codebase from Git to create an application]

// Deploying the database application
include::modules/getting-started-web-console-connecting-a-database.adoc[leveloffset=+1]

// Providing access to the database by creating a secret
include::modules/getting-started-web-console-creating-secret.adoc[leveloffset=+2]

[role="_additional-resources"]
.Additional resources
* xref:../nodes/pods/nodes-pods-secrets.adoc#nodes-pods-secrets-about_nodes-pods-secrets[Understanding secrets]

// Loading data into the database
include::modules/getting-started-web-console-load-data-output.adoc[leveloffset=+2]

// Viewing the application in a web browser
include::modules/getting-started-web-console-view.adoc[leveloffset=+1]
