Skip to content

Commit

Permalink
docs: update k8s version config for EdgeForge (#4766)
Browse files Browse the repository at this point in the history
* docs: update k8s version config

* docs: add pre 4.4.12 info back

---------

Co-authored-by: Lenny Chen <[email protected]>
  • Loading branch information
lennessyy and Lenny Chen authored Nov 21, 2024
1 parent 95e2347 commit b09921c
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,9 @@ artifacts at the same time.
the JSON object corresponding to your Kubernetes distribution.

If you are using a tag that is earlier than v4.4.12, the **k8s_versions.json** file does not exist in those tags.
Instead, open the **Earthfile** in the CanvOS directory. Under `build-provider-images`, remove the lines containing
Kubernetes versions that you do not need.
Instead, open the **Earthfile** in the CanvOS directory. In the file, find the block that starts with
`build-provider-images-fips:` and delete the Kubernetes versions that you do not want. This will speed up the build
process and save storage space.

10. Issue the command below to create an **.arg** file. The **.arg** file uses the default values for the remaining
arguments.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -223,17 +223,13 @@ customization.
cat user-data
```
10. The CanvOS utility uses [Earthly](https://earthly.dev/)(https://earthly.dev/) to build the target artifacts. By
default, images are created for all the Palette-supported Kubernetes versions. Comment out the versions you do not
need in the file **Earthfile** to speed up the build process and save disk space.
10. Open the **k8s_versions.json** file in the CanvOS directory. Remove the Kubernetes versions that you don't need from
the JSON object corresponding to your Kubernetes distribution.
```
build-provider-images:
# BUILD +provider-image --K8S_VERSION=1.24.6
BUILD +provider-image --K8S_VERSION=1.25.2
BUILD +provider-image --K8S_VERSION=1.26.4
BUILD +provider-image --K8S_VERSION=1.27.2
```
If you are using a tag that is earlier than v4.4.12, the **k8s_versions.json** file does not exist in those tags.
Instead, open the **Earthfile** in the CanvOS directory. In the file, find the block that starts with
`build-provider-images-fips:` and delete the Kubernetes versions that you do not want. This will speed up the build
process and save storage space.
11. Issue the following command to start the build process.
Expand Down
14 changes: 10 additions & 4 deletions docs/docs-content/tutorials/edge/deploy-cluster.md
Original file line number Diff line number Diff line change
Expand Up @@ -266,10 +266,16 @@ images are created for all the Palette-supported Kubernetes versions by default.
used in this tutorial, the script builds 14 images. If your machine does not have enough disk space, the build process
will fail silently.

You can exclude image versions you do not need from the build process by commenting out the lines in the
`build-provider-images` parameter in the file **Earthfile** in the **CanvOS** repository. This speeds up build process
and reduces the amount of space required for the build process. For an example of excluding a version from build, refer
to [Build Edge Artifacts guide](../../clusters/edge/edgeforge-workflow/palette-canvos/palette-canvos.md).
If you are using a Git tag earlier than v4.4.12, you can exclude image versions you do not need from the build process
by commenting out the lines in the `build-provider-images` parameter in the file **Earthfile** in the **CanvOS**
repository.

If you are using a Git tag later than v4.4.12, open the **k8s_versions.json** file in the CanvOS directory. Remove the
Kubernetes versions that you don't need from the JSON object corresponding to your Kubernetes distribution.

This speeds up build process and reduces the amount of space required for the build process. For an example of excluding
a version from build, refer to
[Build Edge Artifacts guide](../../clusters/edge/edgeforge-workflow/palette-canvos/palette-canvos.md).

:::

Expand Down

0 comments on commit b09921c

Please sign in to comment.