-
Notifications
You must be signed in to change notification settings - Fork 38
Adds experimental features and OCI storage #179
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
0xavi0
merged 2 commits into
rancher:main
from
0xavi0:2670-experimental-features-and-oci
Sep 5, 2024
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# How to enable experimental features | ||
|
||
Fleet supports experimental features that are disabled by default and that can be enabled by the user. | ||
|
||
Enabling/disabling experimental features is done using extra environment variables that are available when deploying `rancher/fleet`. | ||
|
||
## Enabling an experimental feature | ||
|
||
At the moment we're writing this document, Fleet has OCI storage as an experimental feature. | ||
|
||
### Enabling when installing Fleet stand-alone | ||
|
||
All you need to do is to pass something like: | ||
``` | ||
--set-string extraEnv[0].name=EXPERIMENTAL_OCI_STORAGE \ | ||
--set-string extraEnv[0].value=true \ | ||
``` | ||
to your helm install or update command. | ||
|
||
Please note you have to use `--set-string` because otherwise the boolean value won't work as expected. | ||
|
||
### Enabling when installing Fleet with Rancher | ||
|
||
You can also activate the experimental features in Fleet when installing Rancher. | ||
|
||
The parameters are the same, but you have to add the `fleet.` prefix. | ||
|
||
``` | ||
--set-string fleet.extraEnv[0].name=EXPERIMENTAL_OCI_STORAGE \ | ||
--set-string fleet.extraEnv[0].value=true \ | ||
``` | ||
|
||
## Available experimental features | ||
|
||
Right now Fleet supports the following experimental features: | ||
|
||
* [`EXPERIMENTAL_OCI_STORAGE`](./oci-storage.md) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# OCI Storage | ||
|
||
## Summary | ||
|
||
Fleet stores by default the bundle resources in etcd twice. This is done via the k8s API and there is a size limit, depending on the etcd configuration. | ||
|
||
This feature will allow users to choose an OCI registry as storage for bundle resources. The bundle resource will have an empty resource list and a reference to the OCI repository server. The bundledeployment will not point to a content resource, but to an OCI repository server instead. | ||
|
||
When using this feature the bundle resources are stored once, in the configured OCI registry, and Fleet won't be tied to possible `etcd` size limitations. | ||
|
||
This may me interesting for users who need to store big `Bundles`, and could also be seen as the first step for an `OCIOps` feature in the future. | ||
|
||
Once the OCI registry is enabled, Fleet will use it as the source for storing `Bundle` resources. | ||
When Fleet can't access the OCI registry, it won't fall back to default `etcd` storage. Instead, it will log errors so they can be fixed. | ||
|
||
## Configuring the OCI registry | ||
|
||
OCI registry values should be configured as an extra section in the `GitRepo` yaml. | ||
|
||
There are the fields involved: | ||
``` | ||
// when ociRegistry is defined Fleet will use oci registry as storage | ||
ociRegistry: | ||
// url is the OCI registry url. | ||
url: "docker.io/your-user-here" | ||
// secret name where the credentials for the OCI registry are. | ||
// expects a generic secret with username and password keys set. | ||
authSecretName: oci-secret | ||
// basicHTTP allows Fleet to uses basic http connections to communicate | ||
// with the registry (defaults to false) | ||
basicHTTP: false | ||
// insecureSkipTLS allows connections to the OCI registry | ||
// without certs (defaults to false) | ||
insecureSkipTLS: false | ||
``` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.