3장. Tutorial: Deploying an application by using the CLI


To learn how to stand up an application on OpenShift Container Platform by using the OpenShift CLI (oc), 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:

  1. Create a project for the application.

    This step allows your application to be isolated from other cluster user’s workloads.

  2. 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.

  3. Deploy the front-end application.

    This step deploys the parksmap front-end application, exposes it externally, and scales it up to two instances.

  4. Deploy the back-end application.

    This step deploys the nationalparks back-end application and exposes it externally.

  5. 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 view the national parks application in a web browser.

3.1. Prerequisites

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

  • You have installed the OpenShift CLI (oc).
  • You have access to a test OpenShift Container Platform cluster.

    If your organization does not have a cluster to test on, you can request access to the Developer Sandbox to get a trial of OpenShift Container Platform.

  • You have the appropriate permissions, such as the cluster-admin 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 logged in to your cluster by using the OpenShift CLI (oc).
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 문서 정보

Legal Notice

Theme

© 2026 Red Hat
맨 위로 이동