Find the Best Cosmetic Hospitals

Explore trusted cosmetic hospitals and make a confident choice for your transformation.

“Invest in yourself — your confidence is always worth it.”

Explore Cosmetic Hospitals

Start your journey today — compare options in one place.

OpenShift Tutorial – Basic Learning Workflow

How to login?


oc login https://api.XXXXXXXXXXXXXX.centralindia.aroapp.io:6443 --username=kubeadmin --password=EgzIY-DJPw2-3NXke-HNYmJ

oc login --token=sha256~LLnTlPcjcNjWsQRqnSyTn99LSvxwQdm47gaiEdZJa20 --server=https://api.XXXXXXXXXXXXXX.centralindia.aroapp.io:6443

curl -H "Authorization: Bearer sha256~LLnTlPcjcNjWsQRqnSyTn99LSvxwQdm47gaiEdZJa20" "https://api.XXXXXXXXXXXXXX.centralindia.aroapp.io:6443/apis/user.openshift.io/v1/users/~Code language: JavaScript (javascript)

Login to the Web Console and CLI on CRC

crc console --credentials
eval $(crc oc-env)
oc login -u kubeadmin -p <password> --insecure-skip-tls-verify
Code language: JavaScript (javascript)

Copy the admin URL and kubeadmin credentials → open in browser.


✅ Step 2: Understand Projects (Namespaces)

🔹 List All Projects:

oc get projects
Code language: JavaScript (javascript)

🔹 Create Your Own:

oc new-project demo-app
Code language: JavaScript (javascript)

✅ Step 3: Deploy Your First Application

oc get images
oc new-app --name=my-java-app registry.access.redhat.com/ubi8/openjdk-8-runtime@sha256:00cf28cf9a6c427962f922855a6cc32692c760764ce2ce7411cf605dd510367f
oc expose svc/my-java-app


oc get imagestreams -n openshift
oc new-app --name=my-httpd --image-stream=openshift/httpd
oc expose svc/my-httpd
oc get route my-httpdCode language: JavaScript (javascript)

Test in browser using the exposed route.


✅ Step 4: Work with the Developer Console

  1. Go to the Web Console → Developer View
  2. Switch to demo-app project
  3. Click +Add → Use “Container Image”
  4. Search for image like node:latest, php:8.2-apache, or quay.io/...

This gives visual understanding of how apps, builds, and deployments connect.


✅ Step 5: Build from Source (Git to Deployment)

🔹 Deploy from Git (Node.js example):

oc new-app https://github.com/sclorg/nodejs-ex.git
Code language: JavaScript (javascript)

🔹 Monitor:

oc get builds
oc logs -f bc/nodejs-ex
Code language: JavaScript (javascript)

🔹 Access:

oc expose svc/nodejs-ex
oc get route
Code language: JavaScript (javascript)

✅ Step 6: Scale Applications

🔹 Increase Pods:

oc scale --replicas=3 deployment/nginx

🔹 Check Pods:

oc get pods -o wide
Code language: JavaScript (javascript)

✅ Step 7: Access Pod Shell & Logs

oc rsh <pod-name>
oc logs <pod-name>
Code language: HTML, XML (xml)

Use this for debugging and viewing container state.


✅ Step 8: Set Resource Limits

oc set resources deployment nginx 
  --limits=cpu=500m,memory=256Mi 
  --requests=cpu=200m,memory=128Mi
Code language: JavaScript (javascript)

✅ Step 9: Understand and Apply YAML

  1. Export a deployment: oc get deployment nginx -o yaml > nginx.yaml
  2. Edit and apply: oc apply -f nginx.yaml

✅ Step 10: Use Secrets and ConfigMaps

🔹 Create ConfigMap:

oc create configmap app-config --from-literal=ENV=prod
Code language: JavaScript (javascript)

🔹 Create Secret:

oc create secret generic app-secret --from-literal=DB_PASS=admin123
Code language: JavaScript (javascript)

🔹 Mount or Inject via ENV in deployment YAML.


✅ Step 11: OpenShift Pipelines (Tekton)

  1. In OperatorHub, install OpenShift Pipelines Operator
  2. Create:
    • PipelineResource
    • Task
    • Pipeline
  3. Use the developer console’s Pipelines view to build CI/CD

✅ Step 12: Monitor with Web UI

  • Use Observe → Metrics
  • View Dashboard, Topology, and Builds
  • Use Pod terminal from console

✅ Step 13: Delete a Project

oc delete project demo-app
Code language: JavaScript (javascript)

📚 Bonus Tips:

FeatureCLI Command
List all Podsoc get pods
View eventsoc get events
Port Forwardoc port-forward svc/nginx 8080:80
RoleBindingoc adm policy add-role-to-user admin developer
Enable Dev ViewUse toggle in OpenShift console UI

🧪 Practice Ideas:

  • Deploy a multi-container app with mysql + wordpress
  • Create blue-green deployments
  • Use Tekton pipeline to auto-deploy from GitHub

Find Trusted Cardiac Hospitals

Compare heart hospitals by city and services — all in one place.

Explore Hospitals
I’m a DevOps/SRE/DevSecOps/Cloud Expert passionate about sharing knowledge and experiences. I have worked at <a href="https://www.cotocus.com/">Cotocus</a>. I share tech blog at <a href="https://www.devopsschool.com/">DevOps School</a>, travel stories at <a href="https://www.holidaylandmark.com/">Holiday Landmark</a>, stock market tips at <a href="https://www.stocksmantra.in/">Stocks Mantra</a>, health and fitness guidance at <a href="https://www.mymedicplus.com/">My Medic Plus</a>, product reviews at <a href="https://www.truereviewnow.com/">TrueReviewNow</a> , and SEO strategies at <a href="https://www.wizbrand.com/">Wizbrand.</a> Do you want to learn <a href="https://www.quantumuting.com/">Quantum Computing</a>? <strong>Please find my social handles as below;</strong> <a href="https://www.rajeshkumar.xyz/">Rajesh Kumar Personal Website</a> <a href="https://www.youtube.com/TheDevOpsSchool">Rajesh Kumar at YOUTUBE</a> <a href="https://www.instagram.com/rajeshkumarin">Rajesh Kumar at INSTAGRAM</a> <a href="https://x.com/RajeshKumarIn">Rajesh Kumar at X</a> <a href="https://www.facebook.com/RajeshKumarLog">Rajesh Kumar at FACEBOOK</a> <a href="https://www.linkedin.com/in/rajeshkumarin/">Rajesh Kumar at LINKEDIN</a> <a href="https://www.wizbrand.com/rajeshkumar">Rajesh Kumar at WIZBRAND</a> <a href="https://www.rajeshkumar.xyz/dailylogs">Rajesh Kumar DailyLogs</a>

Related Posts

List of all Job Roles, Job Titles in Software and IT Companies

The software and IT industry is home to a diverse array of job roles and titles, reflecting the dynamic and ever-evolving nature of technology. From core technical…

Read More

Best DevOps Tools in 2024

here’s a clear, structured breakdown of the Best DevOps Tools (grouped by categories), so you can use it for learning, training, or posts. 🚀 Best DevOps Tools…

Read More

OpenShift Install & Configurations using OpenShift Local in windows laptops/desktops

Below is the 100% correct and updated step-by-step guide to install and configure OpenShift Local (aka CRC) on Windows 10/11 laptops or desktops using the correct crc…

Read More

Openshift: How to configure Azure openshift ARO with Custom Domain

Step-by-Step Guide: Configuring Azure Red Hat OpenShift (ARO) with a Custom Domain Setting up a custom domain for your ARO cluster involves both Azure and DNS provider…

Read More

Openshift: Lab 10 – View performance information using the OpenShift web console

Rajesh Kumar I’m a DevOps/SRE/DevSecOps/Cloud Expert passionate about sharing knowledge and experiences. I have worked at Cotocus. I share tech blog at DevOps School, travel stories at…

Read More

Openshift: How to add Helm Repository in Openshift

Adding a Helm repository in OpenShift is a common step to manage and deploy Helm charts in your OpenShift cluster. OpenShift supports Helm CLI out of the…

Read More
Subscribe
Notify of
guest
0 Comments
Newest
Oldest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x