1
0
mirror of synced 2026-02-06 19:05:55 +00:00
Commit Graph

583 Commits

Author SHA1 Message Date
Jesper Axelsen
3fb05a604f fix: #5654 by check if both --chart and --chart-ref are set
Signed-off-by: Jesper Axelsen <jesperbaxelsen@gmail.com>
2025-12-10 22:08:31 +01:00
Anshuman Singh
0ba28f3f91 Allow option to skip tenant namespace creation
Add --skip-namespace flag to the 'create tenant' command to skip automatic
namespace creation when the namespace already exists.

Signed-off-by: Anshuman Singh <anshumanchauhan9@gmail.com>
2025-11-21 17:46:12 +05:30
Matheus Pimenta
69feb7214a Fix panic on reconcile with source of ExternalArtifact kind
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-11-17 13:31:13 +00:00
Daniel Guns
cdc37c304a Adding export source external
Signed-off-by: Daniel Guns <danbguns@gmail.com>
2025-10-24 14:52:36 -03:00
Akshat Sinha
5b37a6b04b fix(cli): handle error when writing password prompt and correct spelling (i) Add error handling for fmt.Fprint when writing password prompt to stdout (ii) Fixed : initalization to initialization in the commented region
Signed-off-by: Akshat Sinha <akshatsinhasramhardy@gmail.com>
2025-10-13 20:21:49 +05:30
Daniel Guns
1055f28524 Adding get source external-artifact
Signed-off-by: Daniel Guns <danbguns@gmail.com>
2025-10-09 08:45:01 -03:00
Matheus Pimenta
7c5fb2297c Fix flux migrate -f not considering kind comments
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-10-04 14:26:54 +01:00
Matheus Pimenta
83213ce83f Fix migrate -f command to work with comments
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-10-03 14:54:41 +01:00
Stefan Prodan
0255957dd7 Improve flux migrate for live cluster migrations
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-10-03 15:24:44 +03:00
Matheus Pimenta
a9b5be7ff4 Extend flux migrate to work with local files
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-10-02 15:35:02 +01:00
Matheus Pimenta
039d79b3c2 Fix flux push artifact not working with --provider
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-10-01 09:37:35 +01:00
Matheus Pimenta
b5ecb9bc56 Add --show-history flag to debug kustomization
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-09-26 10:01:31 +01:00
Stefan Prodan
6185366b8a Migrate create commands to DependencyReference type
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-25 18:22:08 +03:00
prasad89
8000a41015 Add support for custom storage namespace in HelmRelease creation
Signed-off-by: prasad89 <vdbhaleraovb@gmail.com>
2025-09-24 21:46:06 +05:30
Stefan Prodan
55bb3fe643 Set Kubernetes 1.32 as min supported version
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-24 10:39:53 +03:00
Stefan Prodan
c3eadad983 Add support for ExternalArtifact to flux trace
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-23 15:49:19 +03:00
lukas8219
48d509d838 Implement flux [reconcile|suspend|resume] image policy commands
Signed-off-by: lukas8219 <lucas.c4d@gmail.com>
2025-09-20 00:00:10 -03:00
fluxcdbot
99b51ad525 Update toolkit components
- image-automation-controller to v1.0.0
  https://github.com/fluxcd/image-automation-controller/blob/v1.0.0/CHANGELOG.md

Signed-off-by: GitHub <noreply@github.com>
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-09-16 12:08:15 +01:00
Stefan Prodan
a317f7c445 Add support for events --for ArtifactGenerator/<name>
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-16 11:17:27 +03:00
Stefan Prodan
698a68424f Add tree artifact generator command
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-16 11:00:17 +03:00
Stefan Prodan
5556a5cc9a Add get artifact generator command
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-16 11:00:12 +03:00
Stefan Prodan
c416671ec4 Add export artifact generator command
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-16 11:00:12 +03:00
Stefan Prodan
f719d2bf76 Use stdout when exporting objects
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-16 11:00:12 +03:00
Stefan Prodan
3542d61afd Add source-watcher to the install and bootstrap commands
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-09-15 23:59:03 +03:00
fluxcdbot
b4bc0d4932 Update toolkit components
- source-controller to v1.7.0
  https://github.com/fluxcd/source-controller/blob/v1.7.0/CHANGELOG.md

Signed-off-by: GitHub <noreply@github.com>
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-09-15 17:33:20 +01:00
Matheus Pimenta
e765897df7 Update image-reflector-controller API imports to v1
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-09-15 13:34:32 +01:00
Parthib Mukherjee
bef6f36755 Add --show-history flag to debug helmrelease
Signed-off-by: Parthib Mukherjee <parthibmukherjee@gmail.com>
2025-09-04 12:44:28 +00:00
S. M. Mohiuddin Khan Shiam
c2a883e25a fix(events): respect --all-namespaces flag
The `flux events` command always applied a namespace filter, even when `--all-namespaces` was set.
This produced incomplete results and confused users expecting cluster-wide events.

Changes made:
* Build `clientListOpts` dynamically.
* Omit `client.InNamespace(...)` when `eventArgs.allNamespaces` is true, ensuring no namespace constraint.

Impact:
`flux events --all-namespaces` now returns events from every namespace, restoring expected functionality without affecting other options.

Signed-off-by: S. M. Mohiuddin Khan Shiam <147746955+mohiuddin-khan-shiam@users.noreply.github.com>
2025-09-01 08:55:15 +01:00
Stefan Prodan
d340f80d75 Update dependencies to Kubernetes v1.34.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-08-30 15:11:43 +03:00
Stefan Prodan
45837d2d1b Implement flux migrate command
The migrate command must be run before a Flux minor version upgrade.
The command migrates the Flux custom resources stored in Kubernetes etcd to their latest API version, ensuring the Flux components can continue to function correctly after the upgrade.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-08-08 13:23:00 +03:00
cappyzawa
8b95a09319 Migrate sourcesecret package to runtime/secrets APIs
The sourcesecret package now uses pkg/runtime/secrets factory
functions instead of the previous monolithic approach. This
provides standardized secret generation with consistent
validation and error handling across all authentication types.

Signed-off-by: cappyzawa <cappyzawa@gmail.com>
2025-07-29 22:50:56 +09:00
Matheus Pimenta
b3b404ed30 Upgrade fluxcd/pkg dependencies
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-07-15 10:32:35 +01:00
Stefan Prodan
600ec37524 Fix flux push artifact for insecure registries
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-07-10 12:38:53 +03:00
Daniel Guns
5a4bc9410b Promote image CLI commands to stable
Remove experimental status from flux image commands in preparation
for GA release of image automation APIs.

Partial fix for #5411

Signed-off-by: Daniel Guns <danbguns@gmail.com>
2025-06-25 20:52:11 -03:00
cappyzawa
4c343893c5 refactor: cleanup GetArtifactRegistryCredentials error handling
Update fluxcd/pkg/auth to v0.18.0 and simplify error handling for
GetArtifactRegistryCredentials() following the improvements made in
the library.

Similar to fluxcd/image-reflector-controller#786, this removes
unnecessary nil checks as the function now returns errors directly
for unsupported providers.

- Replace authentication code in push_artifact.go with loginWithProvider()
- Remove unnecessary authenticator nil check in oci.go
- Remove unused imports (errors, auth packages)

Signed-off-by: cappyzawa <cappyzawa@gmail.com>
2025-06-21 14:11:18 +09:00
Stefan Bickel
1d34e5355b Make golden tests pass
Signed-off-by: Stefan Bickel <stefan.bickel@cornelsen.de>
2025-06-13 13:25:26 +02:00
Stefan Bickel
00d0e1af25 Add tests and golden files for create tenant
Signed-off-by: Stefan Bickel <stefan.bickel@cornelsen.de>
2025-06-13 13:25:26 +02:00
Stefan Bickel
9f29702f54 Add cli arg --with-service-account
Signed-off-by: Stefan Bickel <stefan.bickel@cornelsen.de>
2025-06-13 13:25:26 +02:00
cappyzawa
5291902fd7 Use normalize.UnstructuredList instead of ssa.SetNativeKindsDefaults
Signed-off-by: cappyzawa <cappyzawa@gmail.com>
2025-06-13 15:15:47 +09:00
Matheus Pimenta
ec3804cc6f Introduce support for shelling out to Azure binaries in authentication
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-06-09 14:07:51 +01:00
Brock Alberry
06e3047a2f add sparse checkout to cli
Signed-off-by: Brock Alberry <brock.alberry@cse-cst.gc.ca>
2025-06-04 12:04:41 -04:00
Johannes Ibald
cd4244ae65 correct small typo
Signed-off-by: Johannes Ibald <johannes.ibald@etes.de>
2025-06-04 11:21:11 +02:00
Stefan Prodan
79fed691ca Update CLI to OCIRepository v1 (GA)
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-05-28 15:12:17 +03:00
Matheus Pimenta
65766ff4fc Add --interval and --reflect-digest flags to flux create image policy
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-05-28 08:25:10 +01:00
Matheus Pimenta
d82ec5a211 Promote artifact commands to stable
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-05-27 16:53:47 +01:00
Matheus Pimenta
13ec11da58 Fix image-reflector-controller tests after output change
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-05-27 15:57:45 +01:00
Stefan Prodan
a421ce4266 Set Kubernetes 1.31 as min supported version
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2025-05-23 15:15:13 +03:00
Matheus Pimenta
0951061b5e Upgrade fluxcd/pkg packages
Signed-off-by: Matheus Pimenta <matheuscscp@gmail.com>
2025-05-19 14:08:33 +01:00
Max Jonas Werner
3e80c5809e Fix flux trace for HRs from OCIRepositorys
Before:
```
$ flux -n default trace pod default-podinfo-585856f49c-4jl4m
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x40 pc=0x10618da70]

goroutine 1 [running]:
main.traceHelm({0x106dd7b28, 0x14000201490}, {0x12f34c0d8, 0x14000783100}, {{0x1400071e130?, 0x1061e7795?}, {0x1400071e109?, 0x1000d9c84?}}, 0x140006a6030)
	/home/runner/work/flux2/flux2/cmd/flux/trace.go:404 +0x2f0
main.traceObject({0x106dd7b28, 0x14000201490}, {0x12f34c0d8, 0x14000783100}, 0x140006a6030)
	/home/runner/work/flux2/flux2/cmd/flux/trace.go:134 +0x11c
main.traceObjects({0x106dd7b28, 0x14000201490}, {0x12f34c0d8, 0x14000783100}, {0x140006a6040, 0x1, 0x0?})
	/home/runner/work/flux2/flux2/cmd/flux/trace.go:112 +0x74
main.traceCmdRun(0x14000592800?, {0x140003aea80, 0x2, 0x4})
	/home/runner/work/flux2/flux2/cmd/flux/trace.go:107 +0x180
github.com/spf13/cobra.(*Command).execute(0x108341980, {0x140003aea40, 0x4, 0x4})
	/home/runner/go/pkg/mod/github.com/spf13/cobra@v1.8.1/command.go:985 +0x834
github.com/spf13/cobra.(*Command).ExecuteC(0x108329280)
	/home/runner/go/pkg/mod/github.com/spf13/cobra@v1.8.1/command.go:1117 +0x344
github.com/spf13/cobra.(*Command).Execute(...)
	/home/runner/go/pkg/mod/github.com/spf13/cobra@v1.8.1/command.go:1041
main.main()
	/home/runner/work/flux2/flux2/cmd/flux/main.go:189 +0x78
```

After:

```
 $ ~/dev/flux/flux2/bin/flux -n default trace pod default-podinfo-585856f49c-4jl4m

Object:         Pod/default-podinfo-585856f49c-4jl4m
Namespace:      default
Status:         Managed by Flux
---
HelmRelease:    podinfo
Namespace:      flux-system
Target:         default
Revision:       6.8.0+2360bdf32ddc
Status:         Last reconciled at 2025-05-14 16:10:37 +0200 CEST
Message:        Helm install succeeded for release default/default-podinfo.v1 with chart podinfo@6.8.0+2360bdf32ddc
---
OCIRepository:   podinfo
Namespace:       flux-system
URL:             oci://ghcr.io/stefanprodan/charts/podinfo
Tag:             6.8.0
Revision:        6.8.0@sha256:2360bdf32ddc50c05f8e128118173343b0a012a338daf145b16e0da9c80081a4
Status:          Last reconciled at 2025-05-14 16:09:17 +0200 CEST
Message:         stored artifact for digest '6.8.0@sha256:2360bdf32ddc50c05f8e128118173343b0a012a338daf145b16e0da9c80081a4'
```

Signed-off-by: Max Jonas Werner <max@coppersoft.com>
2025-05-14 18:02:18 +02:00
Daniel Guns
392a33d425 Change error reporting in get.go from logger.Failure to fmt.Errorf to give non 0 exit code
Signed-off-by: Daniel Guns <danbguns@gmail.com>
2025-05-07 19:11:16 -03:00