|
| 1 | +// Module included in the following assemblies: |
| 2 | +// |
| 3 | +// * microshift_install/microshift-embed-into-rpm-ostree.adoc |
| 4 | + |
| 5 | +:_mod-docs-content-type: PROCEDURE |
| 6 | +[id="microshift-enable-eus-repos_{context}"] |
| 7 | += Enabling extended support repositories for image building |
| 8 | + |
| 9 | +If you have an extended support (EUS) release of {microshift-short} or {op-system-base-full}, you must enable the {op-system-base} EUS repositories for image builder to use. If you do not have an EUS version, you can skip these steps. |
| 10 | + |
| 11 | +.Prerequisites |
| 12 | + |
| 13 | +* You have an EUS version of {microshift-short} or {op-system-base}, or you are updating to one. |
| 14 | +* You have root-user access to your build host. |
| 15 | +* You reviewed the link:https://docs.redhat.com/en/documentation/red_hat_build_of_microshift/4.16/html/installing/microshift-install-rpm#microshift-install-rpm-rhde-compatibility-table[{op-system-bundle} release compatibility matrix]. |
| 16 | +
|
| 17 | +include::snippets/microshift-unsupported-config-warn.adoc[leveloffset=+1] |
| 18 | + |
| 19 | +.Procedure |
| 20 | + |
| 21 | +. Create the `/etc/osbuild-composer/repositories` directory by running the following command: |
| 22 | ++ |
| 23 | +[source,terminal] |
| 24 | +---- |
| 25 | +$ sudo mkdir -p /etc/osbuild-composer/repositories |
| 26 | +---- |
| 27 | + |
| 28 | +. Copy the `/usr/share/osbuild-composer/repositories/rhel-9.4.json` file into the `/etc/osbuild-composer/repositories` directory by running the following command: |
| 29 | ++ |
| 30 | +[source,terminal] |
| 31 | +---- |
| 32 | +$ sudo cp /usr/share/osbuild-composer/repositories/rhel-9.4.json /etc/osbuild-composer/repositories/rhel-9.4.json |
| 33 | +---- |
| 34 | + |
| 35 | +. Update the `baseos` source by modifying the `/etc/osbuild-composer/repositories/rhel-9.4.json` file with the following values: |
| 36 | ++ |
| 37 | +[source,terminal] |
| 38 | +---- |
| 39 | +# ... |
| 40 | +"baseurl": "https://cdn.redhat.com/content/eus/rhel<9>/<9.4>//baseos/os", # <1> |
| 41 | +# ... |
| 42 | +---- |
| 43 | +<1> Replace _<9>_ with the major {op-system-base} version you are using, and replace _<9.4>_ with the _<major.minor>_ version. Be certain that the {op-system-base} version you choose is compatible with the {microshift-short} version you are using. |
| 44 | + |
| 45 | +. Optional. Apply the `baseos` update by running the following command: |
| 46 | ++ |
| 47 | +[source,terminal] |
| 48 | +---- |
| 49 | +$ sudo sed -i "s,dist/rhel<9>/<9.4>/$(uname -m)/baseos/,eus/rhel<9>/<9.4>/$(uname -m)/baseos/,g" \ |
| 50 | +/etc/osbuild-composer/repositories/rhel-<9.4>.json # <1> |
| 51 | +---- |
| 52 | +<1> Replace _<9>_ with the major {op-system-base} version you are using, and replace _<9.4>_ with the _<major.minor>_ version. Be certain that the {op-system-base} version you choose is compatible with the {microshift-short} version you are using. |
| 53 | + |
| 54 | +. Update the `appstream` source by modifying the `/etc/osbuild-composer/repositories/rhel-<major.minor>.json` file with the following values: |
| 55 | ++ |
| 56 | +[source,terminal] |
| 57 | +---- |
| 58 | +# ... |
| 59 | +"baseurl": "https://cdn.redhat.com/content/eus/rhel<9>/<9.4>//appstream/os", # <1> |
| 60 | +# ... |
| 61 | +---- |
| 62 | +<1> Replace _<9>_ with the major {op-system-base} version you are using, and replace _<9.4>_ with the _<major.minor>_ version. Be certain that the {op-system-base} version you choose is compatible with the {microshift-short} version you are using. |
| 63 | + |
| 64 | +. Optional. Apply the `appstream` update by running the following command: |
| 65 | ++ |
| 66 | +[source,terminal] |
| 67 | +---- |
| 68 | +$ sudo sed -i "s,dist/rhel<9>/<9.4>/$(uname -m)/appstream/,eus/rhel<9>/<9.4>/$(uname -m)/appstream/,g" \ |
| 69 | +/etc/osbuild-composer/repositories/rhel-<9.4>.json # <1> |
| 70 | +---- |
| 71 | +<1> Replace _<9>_ with the major {op-system-base} version you are using, and replace _<9.4>_ with the _<major.minor>_ version. Be certain that the {op-system-base} version you choose is compatible with the {microshift-short} version you are using. |
| 72 | + |
| 73 | +.Verification |
| 74 | + |
| 75 | +You can verify the repositories by using the `composer-cli` tool to display information about the source. |
| 76 | + |
| 77 | +. Verify the `baseos` source by running the following command: |
| 78 | ++ |
| 79 | +[source,terminal] |
| 80 | +---- |
| 81 | +$ sudo composer-cli sources info baseos | grep 'url =' |
| 82 | +---- |
| 83 | +.Example output |
| 84 | ++ |
| 85 | +[source,text] |
| 86 | +---- |
| 87 | +url = "https://cdn.redhat.com/content/eus/rhel9/9.4/x86_64/baseos/os" |
| 88 | +---- |
| 89 | + |
| 90 | +. Verify the `appstream` source by running the following command: |
| 91 | ++ |
| 92 | +[source,terminal] |
| 93 | +---- |
| 94 | +$ sudo composer-cli sources info appstream | grep 'url =' |
| 95 | +---- |
| 96 | +.Example output |
| 97 | ++ |
| 98 | +[source,text] |
| 99 | +---- |
| 100 | +url = "https://cdn.redhat.com/content/eus/rhel9/9.4/x86_64/appstream/os" |
| 101 | +---- |
| 102 | + |
| 103 | +.Troubleshooting |
| 104 | + |
| 105 | +* If you cannot verify the updated sources, restart the host and run the verification steps again. |
0 commit comments