Commit Graph

496 Commits (52f1ae2df77ff4309daaa93032526a4444bea728)

Author SHA1 Message Date
Stefan Prodan 52f1ae2df7
Mark `HelmRelease` commands as GA
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan 8856de1478
Update `HelmRelease` API to v2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan 472396728b
Adapt HelmRelease revision to API v2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Max Jonas Werner 18d5ec4ecd
Add `(create|delete|export) source chart` commands
The `create source chart` command supports all HelmChart.spec fields
except `.valuesFiles` and `ignoreMissingValuesFiles` as these are
assumingly rarely used fields and the CLI usually only supports
commonly used ones.

closes #4760

Co-authored-by: Stefan Prodan <stefan.prodan@gmail.com>
Signed-off-by: Max Jonas Werner <mail@makk.es>
8 months ago
frekw 26109ee821 Add `--reproducible` flag to `flux push artifact`
This makes the pushed artifact have the exact same hash if the contents
are the same.

E.g
```
flux push artifact oci://repo/image:tag1 --source deploy --revision="test" --path=deploy --reproducible
flux push artifact oci://repo/image:tag2 --source deploy --revision="test" --path=deploy --reproducible
```

will both result in the same sha hash, tagged with `tag1` and `tag2`.

This is useful when producing flux artifacts in a monorepo setup where
you don't want to unnecessarily push new artifacts unless something has
actually changed.

Signed-off-by: frekw <fredrik@warnsberg.se>
8 months ago
Sunny 4edc640d0c
Update image-automation-controller API to v1beta2
Signed-off-by: Sunny <github@darkowlzz.space>
8 months ago
Stefan Prodan aae086c508
Migrate `flux uninstall` to Helm Source API v1
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan e40961c6d0
Migrate `flux trace` to Helm Source API v1
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan 315c53a717
Migrate `flux events` to Helm Source API v1
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan 6baefa2586
Mark `source helm` commands as GA
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan 1aaa48fa09
Update Helm Source APIs to v1 (GA)
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
8 months ago
Stefan Prodan 7027e823d8
Add `--ssh-hostkey-algos` flag to bootstrap command
Allow configuring the list of host key algorithms to use for
SSH connections initialized by the CLI during bootstrap.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
9 months ago
Jason c49ba9d310 Add command for creating notation configuration secrets
Signed-off-by: Jason <jagoodse@microsoft.com>
9 months ago
Max Jonas Werner 1bb92548e4
Add flags for issuer/subject OCI signature verification
This change introduces two new flags to `create source oci` for
providing the values to the
`OCIRepository.spec.verify.matchOIDCIdentity.(issuer,subject)` fields.

Signed-off-by: Max Jonas Werner <mail@makk.es>
9 months ago
toomaj 9ff9f2beba
add support for bearer token as header to bootstrap git
Signed-off-by: toomaj <toomaj@tuta.io>

Set tokenAuth to true with withBearerToken

Signed-off-by: toomaj <toomaj@tuta.io>

Set breaderToken if tokenAuth & withBearerToken were set

Signed-off-by: toomaj <toomaj@tuta.io>
9 months ago
Stefan Prodan 493c1fbdf9
Add `flux envsubst` command
This command can be used to replicate the behavior of the
Flux Kustomization post-build substitutions.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
9 months ago
Stefan Prodan 7d52267fc4
Add `--strict-substitute` flag to `flux build` and `flux diff ks` commands
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
9 months ago
Stefan Prodan 0672c8add2
Generate image pull secret at install
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
9 months ago
Stefan Prodan 05903e2171
Generate image pull secret at bootstrap
Add an optional flag called `--registry-creds` to the bootstrap
command for generating an image pull secret for container images
stored in private registries.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
9 months ago
Rishikesh Nair 1e7dc1b392 Fix a typo in `--force` flag description
Signed-off-by: Rishikesh Nair <alienware505@gmail.com>
11 months ago
Stefan Prodan 5e14014e37
Update dependencies to Kubernetes v1.28.6
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
12 months ago
Kenny Meador 933cf9db02
detect unexpected args on flux check command
Signed-off-by: Kenny Meador <kenny.meador@outlook.com>
12 months ago
Kenny Meador 1a0d931ab5
detect unexpected args in flux stats command
Signed-off-by: Kenny Meador <kenny.meador@outlook.com>
12 months ago
Kenny Meador 145fd1c2f2
Properly detect unexpected arguments
Signed-off-by: Kenny Meador <kenny.meador@outlook.com>
12 months ago
Sven Hoexter 59e5f4c887 Remove duplicate part of the reconcile hr --reset help message
Signed-off-by: Sven Hoexter <sven@stormbind.net>
1 year ago
Hidde Beydals bf6754e20c
Properly detect unsupported API errors
This can happen when Custom Resource Definitions do not exist on the
cluster. For example, because only a subset of the Flux controllers are
installed on the cluster.

Previously, the detection was based on a combination of error type and
string matching. However, a more reliable (and maintained)
`apimeta.IsNoMatchError` checker is available upstream. Making it less
likely this suddenly stops to matching properly when Kubernetes changes
things.

Signed-off-by: Hidde Beydals <hidde@hhh.computer>
1 year ago
Stefan Prodan c22d8f28f9
Drop support for Kubernetes EOL versions
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Stefan Prodan 2b653f9cfa
Use `IsObjectNamespaced` from controller-runtime
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Stefan Prodan b4f5d121c8
Update tests to `HelmRelease` v2beta2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Stefan Prodan afcf12194d
Adapt tree command to `HelmRelease` v2beta2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Stefan Prodan 437a943677
Update `HelmRelease` to v2beta2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Stefan Prodan bed6efa671
Add force and reset flags to `flux reconcile hr`
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Hidde Beydals eeaffd5c0e
Update HelmRelease golden file with new message
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
1 year ago
Sunny e901e8b6f8 Update all the references of NC v1beta2 to v1beta3
Signed-off-by: Sunny <darkowlzz@protonmail.com>
1 year ago
Sunny b28b5dd9b9 non-reconciliable & readiness of static objects
Remove reconcile subcommand for static object APIs Alerts and Providers.

Add a isStatic() method on all the object adapters to determine if
they are static and don't have reconciler. The objects that don't
have reconcilers are skipped from reconciliation and readiness
checks like HelmRepository of type OCI.

Add default ready message for `get` subcommand output for static
objects, Alerts, Providers and HelmRepositories of type OCI, as ready
message can't be derived for them from their status.

Signed-off-by: Sunny <darkowlzz@protonmail.com>
1 year ago
Sunny 05c13fe35a check readiness using kstatus
This change replaces all the many functions and ways of calculating
readiness of objects into one unified way that uses kstatus.Compute() to
check if the object is in progress or current. Only the objects that are
current are considered to be ready. This takes advantage of the kstatus
compatibility of Flux's APIs and also makes sure that they remain
kstatus compatible.

The new isObjectReady() function is also aware of static/statusless
objects and knows how to check their readiness using kstatus. This
prepares the CLI for the upcoming static API objects.

All the is*Ready() functions for specific objects have been removed.

This change doesn't affect any of the existing tests results.

Introduce suspend and resume subcommands for alert-provider.

Signed-off-by: Sunny <darkowlzz@protonmail.com>
1 year ago
Somtochi Onyekwere 2289c6cc60 bootstrap: provide better error message on timeout
Check GitRepository and return Ready condition message as part of error
on timeout.

Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
1 year ago
Ernest Wong 5685afb9d5 Fix typos in flux bootstrap documentation
Signed-off-by: Ernest Wong <chwong719@gmail.com>
1 year ago
Somtochi Onyekwere fd163ddcf2 show cluster instance name and version in flux check and flux version
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
1 year ago
Vinícius Garcia b596aefb91 Fix flux install command so it returns an error when unexpected arguments are passed
Co-authored-by: Max Jonas Werner <makkes@users.noreply.github.com>
Signed-off-by: Vinícius Garcia <vingarcia00@gmail.com>
1 year ago
Stefan Prodan 80efd29ec0
Update dependencies
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
1 year ago
Somtochi Onyekwere aca461912c make flux events work with lowercased kinds
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
1 year ago
Matthew Clarke e184ef2618
fix build_artifact.go typo
Signed-off-by: Matthew Clarke <matthewclarke47@gmail.com>
1 year ago
Hidde Beydals e73d1acb20
Tweak permissions on created files
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
1 year ago
Jabar Asadi dcbca6b1bf
feat: add gitea bootstrapper
Signed-off-by: Jabar Asadi <jasadi@d2iq.com>
1 year ago
Somtochi Onyekwere 9cd4a7215f Display better uninstall prompt if flux is managed by a different tool
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
1 year ago
Somtochi Onyekwere 2f15ad972b confirm before overriding installation by another manager
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
1 year ago
Somtochi Onyekwere 0eba9662e6 prevent flux install from overriding bootrapped cluster
Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
1 year ago
Hidde Beydals e3f6f0f8b3
misc: `sinceSeconds` -> `sinceDuration`
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
1 year ago
Hidde Beydals f5d3283cff
misc: remove unused bits of code
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
1 year ago