Rook is an open source file, block, and object storage for your cloud native environment and is based on battle tested ceph storage. Rook offers storage for your OpenShift apps through persistent volumes which can be dynamically provisioned with kubernetes StorageClass.
The installation itself is fairly simple and can be drilled down to two high-level steps
$ oc create -f rook-operator.yaml
$ oc create -f rook-cluster.yaml
Detailed Installation Steps
Author's Disclaimer:
This tutorial is for educational purpose only has not been tested for production workload by the author.
Step 1: Clone repo
$ git clone https://github.com/rook/rook.git
$ cd rook/demo/kubernetes/1.5
$ oc new-project rook
Step 2: Grant permissions to rook operator as cluster-admin
$ oc adm policy add-cluster-role-to-user cluster-admin system:serviceaccount:rook:default
$ oc adm policy add-scc-to-user anyuid -z default -n rook
$ oc adm policy add-scc-to-user privileged -z default -n rook
Step 3: Create rook operator
$ oc create -f rook-operator.yaml
$ sleep 10 ##wait for rook operator to be created
$ cat rook-cluster.yaml ##for more options
$ oc create -f rook-cluster.yaml
$ oc get pods -n rook ##wait for rook cluster to be created.
$ oc create -f rook-storageclass.yaml
How do you use Rook?
You can use Rook in the same way that you use other OpenShift storage classes.
For example:
$ oc create -f mysql.yaml -n default ##inside demo/1.5/kubernetes folder.
Note: When provisioning storage, Rook uses a secret called rook-rook-user
. Copy this secret to a different namespace if you want to provision storage on a namespace other than the default.
Want to know more?
About the author
Browse by channel
Automation
The latest on IT automation for tech, teams, and environments
Artificial intelligence
Updates on the platforms that free customers to run AI workloads anywhere
Open hybrid cloud
Explore how we build a more flexible future with hybrid cloud
Security
The latest on how we reduce risks across environments and technologies
Edge computing
Updates on the platforms that simplify operations at the edge
Infrastructure
The latest on the world’s leading enterprise Linux platform
Applications
Inside our solutions to the toughest application challenges
Original shows
Entertaining stories from the makers and leaders in enterprise tech
Products
- Red Hat Enterprise Linux
- Red Hat OpenShift
- Red Hat Ansible Automation Platform
- Cloud services
- See all products
Tools
- Training and certification
- My account
- Customer support
- Developer resources
- Find a partner
- Red Hat Ecosystem Catalog
- Red Hat value calculator
- Documentation
Try, buy, & sell
Communicate
About Red Hat
We’re the world’s leading provider of enterprise open source solutions—including Linux, cloud, container, and Kubernetes. We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.
Select a language
Red Hat legal and privacy links
- About Red Hat
- Jobs
- Events
- Locations
- Contact Red Hat
- Red Hat Blog
- Diversity, equity, and inclusion
- Cool Stuff Store
- Red Hat Summit