We will be creating a single-node cluster for MicroShift.

Once you’ve downloaded and installed CRC on your machine, you’re ready to use CRC by creating a cluster. MicroShift is not the default cluster type that would be created when no explicit configuration is provided.

In order to instruct CRC to create a MicroShift cluster, we need to update CRC configuration:

$ crc config set preset microshift

Set up environment for your cluster

Before starting cluster, you need to prepare your machine for creating a Virtual Machine. MicroShift cluster would be started inside that Virtual Machine. In order to do that use crc setup command.

Open a terminal with a user account with administrator access (but not logged in as root user) and run:

$ crc setup

Start your cluster

Once you’ve set up environment for your MicroShift cluster, you can go ahead and start it.

$ crc start

Deploy a sample application to your MicroShift cluster

Create a sample deployment and expose it on port 8080:

$ oc create deployment hello-crc --image=registry.access.redhat.com/ubi8/httpd-24
$ oc expose deployment hello-crc --type=NodePort --port=8080
$ oc expose svc/hello-crc

Wait for application pod to become ready and access application via route:

$ oc get routes
$ curl http://hello-crc-default.apps.crc.testing