Skip to content

Commit 65843f3

Browse files
authored
Merge pull request migtools#4 from anarnold97/MTA-2850-Configuration-doc-OCP-Local
MTA-2850: Installing and Configuring OCP Local
2 parents f69f98b + db96e11 commit 65843f3

File tree

5 files changed

+326
-39
lines changed

5 files changed

+326
-39
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
:_content-type: CONCEPT
2+
[id="mta-7-configuration-web-console-on-ocp-local_{context}"]
3+
= Configuration of the {ProductName} Operator in a {rh-ocp-local} environment
4+
5+
The following table shows the recommended minimum configurations of {rh-ocp-local} tested:
6+
7+
[width="100%",cols="25%,25%,25%",options="header",]
8+
|===
9+
|Memory (GiB)
10+
|CPU
11+
|Disk sze (GiB)
12+
13+
|20
14+
|5
15+
|110
16+
17+
|20
18+
|5
19+
|35, with the {ProductShortName} Operator configurations `cache_data_volume_size` and `hub_bucket_volume_size` set to 5GiB.
20+
|===
Lines changed: 285 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,285 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * docs/web-console-guide/master.adoc
4+
5+
:_content-type: PROCEDURE
6+
[id="mta-7-installing-web-console-on-ocp-local_{context}"]
7+
= Installing and configuring the {ProductName} Operator in a {rh-ocp-local} environment
8+
9+
{rh-ocp-local} provides a quick and easy way to set up a local OpenShift cluster on your desktop or laptop. This local cluster allows you to test your applications and configuration parameters before sending them to production.
10+
11+
[id="mta-7-ocp-os-sys-reqs_{context}"]
12+
== Operating system requirements
13+
14+
{rh-ocp-local} requires the following minimum version of a supported operating system:
15+
16+
[id="mta-7-ocp-local-windows-reqs_{context}"]
17+
=== {rh-ocp-local} requirements on Microsoft Windows
18+
19+
On Microsoft Windows, {rh-ocp-local} requires the Windows 10 Fall Creators Update (version 1709) or later. {rh-ocp-local} does not run on earlier versions of Microsoft Windows. Microsoft Windows 10 Home Edition is not supported.
20+
21+
[id="mta-7-ocp-local-macos-reqs_{context}"]
22+
=== {rh-ocp-local} requirements on macOS
23+
24+
On macOS, {rh-ocp-local} requires macOS 11 Big Sur or later. {rh-ocp-local} does not run on earlier versions of macOS.
25+
26+
[id="mta-7-ocp-local-local-reqs_{context}"]
27+
=== {rh-ocp-local} requirements on Linux
28+
29+
On Linux, {rh-ocp-local} is supported only on the latest two Red Hat Enterprise Linux 8 and 9 minor releases and on the latest two stable Fedora releases.
30+
31+
When using Red Hat Enterprise Linux, the machine running {rh-ocp-local} must be registered with the Red Hat Customer Portal.
32+
33+
Ubuntu 18.04 LTS or later and Debian 10 or later are not supported and might require manual setup of the host machine.
34+
35+
==== Required software packages for Linux
36+
37+
{rh-ocp-local} requires the `libvirt` and `NetworkManager` packages to run on Linux:
38+
39+
* On *Fedora* and *Red Hat Enterprise Linux* run:
40+
41+
+
42+
[source,terminal]
43+
----
44+
sudo dnf install NetworkManager
45+
----
46+
47+
* On *Debian/Ubuntu* run:
48+
+
49+
[source,terminal]
50+
----
51+
sudo apt install qemu-kvm libvirt-daemon libvirt-daemon-system network-manager
52+
----
53+
54+
[id="mta-7-installing-ocp-local_{context}"]
55+
== Installing the {ProductName} Operator in a {rh-ocp-local} environment
56+
57+
To install {rh-ocp-local}:
58+
59+
. Download the latest release of link:https://console.redhat.com/openshift/create/local[{rh-ocp-local}] for your platform.
60+
61+
.. Download *OpenShift Local*.
62+
63+
.. Download *pull secret*.
64+
65+
. Assuming you saved the archive in the `~/Downloads directory`, follow these steps:
66+
67+
+
68+
[source,terminal]
69+
----
70+
cd ~/Downloads
71+
----
72+
73+
+
74+
[source,terminal]
75+
----
76+
tar xvf crc-linux-amd64.tar.xz
77+
----
78+
79+
. Copy the `crc` executable to it:
80+
81+
+
82+
[source,terminal]
83+
----
84+
cp ~/Downloads/crc-linux-<version-number>-amd64/crc ~/bin/crc
85+
----
86+
. Add the `~/bin/crc` directory to your `$PATH` variable:
87+
88+
+
89+
[source,terminal]
90+
----
91+
export PATH=$PATH:$HOME/bin/crc
92+
----
93+
+
94+
[source,terminal]
95+
----
96+
echo 'export PATH=$PATH:$HOME/bin/crc' >> ~/.bashrc
97+
----
98+
99+
. To disable telemetry, run the following command:
100+
101+
+
102+
[source,terminal]
103+
----
104+
crc config set consent-telemetry no
105+
----
106+
107+
[NOTE]
108+
====
109+
For macOS, download the relevant *crc-macos-installer.pkg*.
110+
111+
. Navigate to *Downloads* using *Finder*.
112+
. Double-click on `crc-macos-installer.pkg`.
113+
====
114+
115+
[id="mta-7-set-up-ocp-local_{context}"]
116+
== Setting up {rh-ocp-local}
117+
118+
The `crc setup` command performs operations to set up the environment of your host machine for the {rh-ocp-local} instance.
119+
120+
The `crc setup` command creates the `~/.crc directory`.
121+
122+
. Set up your host machine for {rh-ocp-local}:
123+
124+
+
125+
[source,terminal]
126+
----
127+
crc setup
128+
----
129+
130+
[id="mta-7-starting-ocp-local_{context}"]
131+
== Starting the {rh-ocp-local} instance
132+
133+
{rh-ocp-local} presets represent a managed container runtime, and the lower bounds of system resources required by the instance to run it.
134+
135+
[NOTE]
136+
====
137+
* On Linux or macOS, ensure that your user account has permission to use the `sudo` command.
138+
* On Microsoft Windows, ensure that your user account can elevate to Administrator privileges.
139+
====
140+
141+
The `crc start` command starts the {rh-ocp-local} instance and configured container runtime. It offers the following flags:
142+
143+
[width="100%",cols="17%,15%,34%,34%",options="header",]
144+
|===
145+
146+
|Flags
147+
|Type
148+
|Description
149+
|Default value
150+
151+
| -b, --bundle
152+
| string
153+
| Bundle path/URI - absolute or local path, HTTP, HTTPS or docker URI, for example, `'https://foo.com/crc_libvirt_4.15.14_amd64.crcbundle', 'docker://quay.io/myorg/crc_libvirt_4.15.14_amd64.crcbundle:2.37.1'`
154+
| default `'/home/<user>/.crc/cache/ crc_libvirt_4.15.14_amd64.crcbundle'`
155+
156+
|-c, –cpus
157+
|int
158+
|Number of CPU cores to assign to the instance
159+
| 4
160+
161+
|–disable-update-check
162+
|
163+
|Do not check for update
164+
|
165+
166+
|-d, –disk-size
167+
|uint
168+
|Total size in GiB of the disk used by the instance
169+
|31
170+
171+
|-h, –help
172+
|
173+
|Help for start
174+
|
175+
176+
|-m, –memory
177+
|int
178+
|MiB of memory to assign to the instance
179+
|10752
180+
181+
|-n, –nameserver
182+
| string |IPv4 address of name server to use for the instance
183+
|
184+
185+
|-o, –output
186+
|string
187+
|Output format in JSON
188+
|
189+
190+
|-p, –pull-secret-file
191+
| string
192+
|File path of image pull secret (download from https://console.redhat.com/openshift/create/local) |
193+
|===
194+
195+
It also offers the following global flags:
196+
197+
[width="100%",cols="17%,15%,34%,34%",options="header",]
198+
|===
199+
200+
|Flags
201+
|Type
202+
|Description
203+
|Default value
204+
|–log-level
205+
|string
206+
|log level for example:
207+
208+
* `+debug+`
209+
210+
* `+info+`
211+
212+
* `+warn+`
213+
214+
* `+error+`
215+
|`+info+`
216+
217+
|===
218+
219+
The default configuration creates a virtual machine (VM) with 4 virtual CPUs, a disk size of 31 GiB, and 10 GiB of RAM. However, this default configuration is not sufficent to stably run {ProductShortName}.
220+
221+
To increase the number of virtual CPUs to 6, the disk-size to 200 GiB, and the memory to 20 GiB, run `crc config` as follows:
222+
+
223+
[source,terminal]
224+
----
225+
crc config set cpus 6
226+
----
227+
228+
+
229+
[source,terminal]
230+
----
231+
crc config set disk-size 200
232+
----
233+
234+
+
235+
[source,terminal]
236+
----
237+
$ crc config set memory 20480
238+
----
239+
240+
To check the configuration, run:
241+
+
242+
[source,terminal]
243+
----
244+
crc config view
245+
----
246+
247+
.Example Output
248+
+
249+
[source,terminal]
250+
----
251+
- consent-telemetry : yes
252+
- cpus : 6
253+
- disk-size : 200
254+
- memory : 16384
255+
----
256+
257+
[NOTE]
258+
====
259+
Changes to the inputted configuration property are only applied when the CRC instance is started.
260+
261+
If you already have a running CRC instance, for this configuration change to take effect, stop the CRC instance with `crc stop` and restart it with `crc start`.
262+
====
263+
264+
[id="mta-7-status-ocp-local_{context}"]
265+
== Checking the status of {rh-ocp-local} instance
266+
267+
To check the status of your {rh-ocp-local} instance, run:
268+
269+
+
270+
[source,terminal]
271+
----
272+
crc status
273+
----
274+
275+
.Example Output
276+
+
277+
[source,terminal]
278+
----
279+
CRC VM: Running
280+
OpenShift: Starting (v4.15.14)
281+
RAM Usage: 9.25GB of 20.97GB
282+
Disk Usage: 31.88GB of 212.8GB (Inside the CRC VM)
283+
Cache Usage: 26.83GB
284+
Cache Directory: /home/<user>/.crc/cache
285+
----

0 commit comments

Comments
 (0)