此内容没有您所选择的语言版本。
Chapter 4. Deploying Red Hat Quay
This procedure:
- Installs the Red Hat Quay Setup Operator on OpenShift from the OperatorHub
- Deploys a Red Hat Quay cluster on OpenShift with the Setup Operator
You have the option of changing dozens of settings before deploying the Red Hat Quay Setup Operator. The Operator automates the entire start-up process, by-passing the Red Hat Quay config tool. You can choose to skip the Operator’s automated configuration and use the config tool directly.
Prerequisites
- An OpenShift 3.x or 4.x cluster
- Cluster-scope admin privilege to the OpenShift cluster
Procedure
You have two choices for deploying the Red Hat Quay Operator:
-
Advanced Setup: Go through the
Customizing your Red Hat Quay clustersection and change any setting you desire before running this procedure. - Standard Setup: Just step through the procedure as is to use all the default setting.
4.1. Install the Red Hat Quay Setup Operator 复制链接链接已复制到粘贴板!
-
From the OpenShift console, select Operators
OperatorHub, then select the Red Hat Quay Operator. - Select Install. The Operator Subscription page appears.
Choose the following then select Subscribe:
- Installation Mode: Select a specific namespace to install to
- Update Channel: Choose the update channel (only one may be available)
- Approval Strategy: Choose to approve automatic or manual updates
4.2. Deploy a Red Hat Quay ecosystem 复制链接链接已复制到粘贴板!
- See the Accessing Red Hat Quay article for information on getting credentials needed to obtain the quay container from Quay.io. Then put those credentials in a file. In this example, we create a config.json in the local directory.
Create a secret that includes your credentials, as follows:
$ oc create secret generic redhat-pull-secret \ --from-file=".dockerconfigjson=config.json" --type='kubernetes.io/dockerconfigjson'Create a custom resource file (in this example, named
quayecosystem_cr.yaml) or copy one from the quay-operator examples page. This example uses default settings:apiVersion: redhatcop.redhat.io/v1alpha1 kind: QuayEcosystem metadata: name: example-quayecosystem spec: quay: imagePullSecretName: redhat-pull-secret-
Go through the
Customizing your Red Hat Quay clustersection to choose configuration settings you want to change. Deploy the Quay ecosystem from your custom resource file as follows:
$ oc create -f quayecosystem_cr.yamlDeploying the custom resource automatically creates and configures the Red Hat Quay cluster, which includes the Red Hat Quay, PostgreSQL, and Redis services.
To check the status of your Red Hat Quay cluster, log in to your OpenShift web console, select Projects, then select the
quay-enterpriseproject to see the following:
If Red Hat Quay is running, here is how to get started using your Red Hat Quay configuration:
Get the route to your new Red Hat Quay cluster as follows:
$ oc get route NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD example-quayecosystem-quay example-quayecosystem-quay-default.example.com example-quayecosystem-quay 8443 passthrough/Redirect None-
Using that route, log in with the superuser credentials (Username:
quayand Password:passwordor change credentials as described in the next section)
Additional resources
- For more details on the Red Hat Quay Setup Operator, see the upstream quay-operator project.