1
0
mirror of synced 2026-03-02 11:36:56 +00:00

Compare commits

..

44 Commits
RFC ... v2.2.3

Author SHA1 Message Date
Stefan Prodan
534684601e Merge pull request #4591 from fluxcd/backport-4589-to-release/v2.2.x
[release/v2.2.x] Update dependencies
2024-02-05 15:33:44 +02:00
Stefan Prodan
1feda85ec9 Update dependencies
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
(cherry picked from commit 9c06883ccf)
2024-02-05 13:18:07 +00:00
Stefan Prodan
e3cdb1902c Merge pull request #4588 from fluxcd/backport-4583-to-release/v2.2.x
[release/v2.2.x] Update toolkit components
2024-02-05 14:07:53 +02:00
fluxcdbot
cb0cf95cb8 Update toolkit components
- helm-controller to v0.37.4
  https://github.com/fluxcd/helm-controller/blob/v0.37.4/CHANGELOG.md
- kustomize-controller to v1.2.2
  https://github.com/fluxcd/kustomize-controller/blob/v1.2.2/CHANGELOG.md
- source-controller to v1.2.4
  https://github.com/fluxcd/source-controller/blob/v1.2.4/CHANGELOG.md
- notification-controller to v1.2.4
  https://github.com/fluxcd/notification-controller/blob/v1.2.4/CHANGELOG.md
- image-reflector-controller to v0.31.2
  https://github.com/fluxcd/image-reflector-controller/blob/v0.31.2/CHANGELOG.md
- image-automation-controller to v0.37.1
  https://github.com/fluxcd/image-automation-controller/blob/v0.37.1/CHANGELOG.md

Signed-off-by: GitHub <noreply@github.com>
(cherry picked from commit a30020a6d6)
2024-02-05 11:42:49 +00:00
Stefan Prodan
81f8bf88dd Merge pull request #4587 from fluxcd/backport-4585-to-release/v2.2.x
[release/v2.2.x] build(deps): bump the ci group with 3 updates
2024-02-05 11:44:53 +02:00
dependabot[bot]
aa4cad4740 build(deps): bump the ci group with 3 updates
Bumps the ci group with 3 updates: [anchore/sbom-action](https://github.com/anchore/sbom-action), [sigstore/cosign-installer](https://github.com/sigstore/cosign-installer) and [peter-evans/create-pull-request](https://github.com/peter-evans/create-pull-request).

Updates `anchore/sbom-action` from 0.15.5 to 0.15.8
- [Release notes](https://github.com/anchore/sbom-action/releases)
- [Commits](24b0d52385...b6a39da807)

Updates `sigstore/cosign-installer` from 3.3.0 to 3.4.0
- [Release notes](https://github.com/sigstore/cosign-installer/releases)
- [Commits](9614fae9e5...e1523de757)

Updates `peter-evans/create-pull-request` from 5.0.2 to 6.0.0
- [Release notes](https://github.com/peter-evans/create-pull-request/releases)
- [Commits](153407881e...b1ddad2c99)

---
updated-dependencies:
- dependency-name: anchore/sbom-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: ci
- dependency-name: sigstore/cosign-installer
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: ci
- dependency-name: peter-evans/create-pull-request
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: ci
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 976f40b642)
2024-02-05 09:18:42 +00:00
Stefan Prodan
a3550cce4e Merge pull request #4577 from fluxcd/backport-4554-to-release/v2.2.x
build(deps): Update GitHub workflows
2024-01-30 17:20:43 +02:00
dependabot[bot]
384d472b40 build(deps): bump the ci group with 3 updates
Bumps the ci group with 3 updates: [Azure/login](https://github.com/azure/login), [actions/upload-artifact](https://github.com/actions/upload-artifact) and [anchore/sbom-action](https://github.com/anchore/sbom-action).

Updates `Azure/login` from 1.6.0 to 1.6.1
- [Release notes](https://github.com/azure/login/releases)
- [Commits](e15b166166...cb79c773a3)

Updates `actions/upload-artifact` from 4.1.0 to 4.2.0
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](1eb3cb2b3e...694cdabd8b)

Updates `anchore/sbom-action` from 0.15.3 to 0.15.4
- [Release notes](https://github.com/anchore/sbom-action/releases)
- [Commits](c7f031d924...41f7a6c033)

---
updated-dependencies:
- dependency-name: Azure/login
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: ci
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: ci
- dependency-name: anchore/sbom-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: ci
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 2726da5b85)
2024-01-30 17:06:43 +02:00
Stefan Prodan
aabdd28d9d Merge pull request #4576 from fluxcd/backport-4575-to-release/v2.2.x
[release/v2.2.x] Update dependencies to Kubernetes v1.28.6
2024-01-30 15:06:46 +02:00
Stefan Prodan
297c0f04de Update dependencies to Kubernetes v1.28.6
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
(cherry picked from commit 5e14014e37)
2024-01-30 14:55:17 +02:00
Stefan Prodan
e0bee66876 Merge pull request #4567 from fluxcd/backport-4558-to-release/v2.2.x
[release/v2.2.x] `flux check` should error on unrecognised args
2024-01-26 08:53:15 +02:00
Kenny Meador
32d46e6da3 detect unexpected args on flux check command
Signed-off-by: Kenny Meador <kenny.meador@outlook.com>
(cherry picked from commit 933cf9db02)
2024-01-26 06:24:27 +00:00
Stefan Prodan
1beac67a01 Merge pull request #4559 from fluxcd/backport-4557-to-release/v2.2.x
[release/v2.2.x] `flux stats` should error on unrecognised args
2024-01-23 11:12:58 +02:00
Kenny Meador
148e4015e5 detect unexpected args in flux stats command
Signed-off-by: Kenny Meador <kenny.meador@outlook.com>

(cherry picked from commit 1a0d931ab5)
2024-01-23 07:01:13 +00:00
Stefan Prodan
c631a76250 Merge pull request #4555 from fluxcd/backport-4553-to-release/v2.2.x
[release/v2.2.x] Properly detect unexpected arguments during uninstall
2024-01-22 09:56:22 +02:00
Kenny Meador
9d04f9147c Properly detect unexpected arguments
Signed-off-by: Kenny Meador <kenny.meador@outlook.com>
(cherry picked from commit 145fd1c2f2)
2024-01-22 07:23:14 +00:00
Stefan Prodan
93c127f8e7 Merge pull request #4538 from fluxcd/backport-4535-to-release/v2.2.x
[release/v2.2.x] build(deps): bump github.com/cloudflare/circl from 1.3.6 to 1.3.7
2024-01-08 19:19:54 +02:00
dependabot[bot]
1749169c98 build(deps): bump github.com/cloudflare/circl from 1.3.6 to 1.3.7
Bumps [github.com/cloudflare/circl](https://github.com/cloudflare/circl) from 1.3.6 to 1.3.7.
- [Release notes](https://github.com/cloudflare/circl/releases)
- [Commits](https://github.com/cloudflare/circl/compare/v1.3.6...v1.3.7)

---
updated-dependencies:
- dependency-name: github.com/cloudflare/circl
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 128301199d)
2024-01-08 17:09:13 +00:00
Stefan Prodan
6cb3954044 Merge pull request #4532 from fluxcd/backport-4531-to-release/v2.2.x
[release/v2.2.x] build(deps): bump the ci group with 2 updates
2024-01-08 10:17:12 +02:00
dependabot[bot]
24c77adcbf build(deps): bump the ci group with 2 updates
Bumps the ci group with 2 updates: [google-github-actions/setup-gcloud](https://github.com/google-github-actions/setup-gcloud) and [anchore/sbom-action](https://github.com/anchore/sbom-action).

Updates `google-github-actions/setup-gcloud` from 2.0.0 to 2.0.1
- [Release notes](https://github.com/google-github-actions/setup-gcloud/releases)
- [Changelog](https://github.com/google-github-actions/setup-gcloud/blob/main/CHANGELOG.md)
- [Commits](825196879a...5a5f7b85fc)

Updates `anchore/sbom-action` from 0.15.1 to 0.15.2
- [Release notes](https://github.com/anchore/sbom-action/releases)
- [Commits](5ecf649a41...719133684c)

---
updated-dependencies:
- dependency-name: google-github-actions/setup-gcloud
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: ci
- dependency-name: anchore/sbom-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: ci
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 3294c7c008)
2024-01-08 07:44:48 +00:00
Hidde Beydals
5c5c15ea21 Merge pull request #4506 from fluxcd/backport-4505-to-release/v2.2.x
[release/v2.2.x] Update helm-controller to v0.37.2 in tests
2023-12-19 18:37:14 +01:00
Hidde Beydals
775838d3ad Update helm-controller to v0.37.2 in tests
Signed-off-by: Hidde Beydals <hidde@hhh.computer>
(cherry picked from commit 4b0cda68b1)
2023-12-19 17:27:00 +00:00
Hidde Beydals
eaae83efa4 Merge pull request #4504 from fluxcd/backport-4501-to-release/v2.2.x
[release/v2.2.x] Update toolkit components
2023-12-19 18:14:47 +01:00
fluxcdbot
c1f7f20454 Update toolkit components
- helm-controller to v0.37.2
  https://github.com/fluxcd/helm-controller/blob/v0.37.2/CHANGELOG.md

Signed-off-by: GitHub <noreply@github.com>
(cherry picked from commit 954e682da8)
2023-12-19 17:03:46 +00:00
Hidde Beydals
bba9e0952d Merge pull request #4503 from fluxcd/backport-4499-to-release/v2.2.x
[release/v2.2.x] Fix typo in Git bootstrap
2023-12-19 17:59:34 +01:00
Stuebinger, Bernd
0ea68fd43b Fix typo in bootstrap_plain_git.go
Signed-off-by: Bernd Stübinger <41049452+stuebingerb@users.noreply.github.com>
(cherry picked from commit b93d4a4a17)
2023-12-19 16:47:28 +00:00
Hidde Beydals
492b50e4f0 Merge pull request #4502 from fluxcd/backport-4491-to-release/v2.2.x
[release/v2.2.x] build(deps): bump the ci group with 3 updates
2023-12-19 17:41:56 +01:00
dependabot[bot]
f46f59bbba build(deps): bump the ci group with 3 updates
Bumps the ci group with 3 updates: [korthout/backport-action](https://github.com/korthout/backport-action), [actions/upload-artifact](https://github.com/actions/upload-artifact) and [sigstore/cosign-installer](https://github.com/sigstore/cosign-installer).

Updates `korthout/backport-action` from 2.2.0 to 2.3.0
- [Release notes](https://github.com/korthout/backport-action/releases)
- [Commits](b982d297e3...addffea45a)

Updates `actions/upload-artifact` from 3.1.3 to 4.0.0
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](a8a3f3ad30...c7d193f32e)

Updates `sigstore/cosign-installer` from 3.2.0 to 3.3.0
- [Release notes](https://github.com/sigstore/cosign-installer/releases)
- [Commits](1fc5bd396d...9614fae9e5)

---
updated-dependencies:
- dependency-name: korthout/backport-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: ci
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: ci
- dependency-name: sigstore/cosign-installer
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: ci
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 4f20be427e)
2023-12-19 16:34:02 +00:00
Hidde Beydals
2eb52e314a Merge pull request #4498 from fluxcd/backport-4494-to-release/v2.2.x
[release/v2.2.x] build(deps): bump golang.org/x/crypto from 0.16.0 to 0.17.0
2023-12-19 09:56:21 +01:00
dependabot[bot]
06dd89e160 build(deps): bump golang.org/x/crypto from 0.16.0 to 0.17.0
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.16.0 to 0.17.0.
- [Commits](https://github.com/golang/crypto/compare/v0.16.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/crypto
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 2935bea6a2)
2023-12-19 08:49:16 +00:00
Hidde Beydals
2ac481c889 Merge pull request #4497 from fluxcd/backport-4495-to-release/v2.2.x
[release/v2.2.x] build(deps): bump golang.org/x/crypto from 0.16.0 to 0.17.0 in /tests/integration
2023-12-19 09:48:36 +01:00
dependabot[bot]
f434fed50f build(deps): bump golang.org/x/crypto in /tests/integration
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.16.0 to 0.17.0.
- [Commits](https://github.com/golang/crypto/compare/v0.16.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/crypto
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 284dfc05c6)
2023-12-19 08:41:45 +00:00
Hidde Beydals
01f43fc109 Merge pull request #4496 from fluxcd/backport-4493-to-release/v2.2.x
[release/v2.2.x] build(deps): bump golang.org/x/crypto from 0.16.0 to 0.17.0 in /tests/azure
2023-12-19 09:41:15 +01:00
dependabot[bot]
c369c06731 build(deps): bump golang.org/x/crypto in /tests/azure
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.16.0 to 0.17.0.
- [Commits](https://github.com/golang/crypto/compare/v0.16.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/crypto
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 9db8c4a990)
2023-12-19 08:38:17 +00:00
Hidde Beydals
9b3958825a Merge pull request #4489 from fluxcd/backport-4488-to-release/v2.2.x
[release/v2.2.x] tests: update API dependencies
2023-12-15 11:25:52 +01:00
Hidde Beydals
f581add81c tests: update API dependencies
- github.com/fluxcd/helm-controller/api to v0.37.1
- github.com/fluxcd/kustomize-controller/api to v1.2.1
- github.com/fluxcd/notification-controller/api to v1.2.3
- github.com/fluxcd/source-controller/api to v1.2.3

Signed-off-by: Hidde Beydals <hidde@hhh.computer>
(cherry picked from commit 0e75d96911)
2023-12-15 10:07:37 +00:00
Hidde Beydals
107dbd09ab Merge pull request #4487 from fluxcd/backport-4483-to-release/v2.2.x
[release/v2.2.x] Update toolkit components
2023-12-15 10:49:49 +01:00
fluxcdbot
ec034c0c3c Update toolkit components
- helm-controller to v0.37.1
  https://github.com/fluxcd/helm-controller/blob/v0.37.1/CHANGELOG.md
- kustomize-controller to v1.2.1
  https://github.com/fluxcd/kustomize-controller/blob/v1.2.1/CHANGELOG.md
- source-controller to v1.2.3
  https://github.com/fluxcd/source-controller/blob/v1.2.3/CHANGELOG.md
- notification-controller to v1.2.3
  https://github.com/fluxcd/notification-controller/blob/v1.2.3/CHANGELOG.md

Signed-off-by: GitHub <noreply@github.com>
(cherry picked from commit 9ec8e717ae)
2023-12-15 09:39:53 +00:00
Hidde Beydals
012782448e Merge pull request #4486 from fluxcd/backport-4484-to-release/v2.2.x
[release/v2.2.x] Run conformance tests for Kubernetes v1.29.0
2023-12-15 10:28:16 +01:00
Stefan Prodan
6be9ce2d4e Run conformance tests for Kubernetes v1.29.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
(cherry picked from commit 0cf855f16f)
2023-12-15 10:16:35 +01:00
Stefan Prodan
0a380b1495 Merge pull request #4482 from fluxcd/backport-4481-to-release/v2.2.x
[release/v2.2.x] Remove duplicate part of the reconcile hr --reset help message
2023-12-14 12:46:30 +02:00
Sven Hoexter
aae92ee097 Remove duplicate part of the reconcile hr --reset help message
Signed-off-by: Sven Hoexter <sven@stormbind.net>
(cherry picked from commit 59e5f4c887)
2023-12-14 10:29:53 +00:00
Hidde Beydals
459f6f2c24 Merge pull request #4477 from fluxcd/backport-4476-to-release/v2.2.x
[release/v2.2.x] Properly detect unsupported API errors
2023-12-13 13:37:49 +01:00
Hidde Beydals
986e405ada 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>
(cherry picked from commit bf6754e20c)
2023-12-13 12:26:38 +00:00
29 changed files with 3179 additions and 205 deletions

3
.github/labels.yaml vendored
View File

@@ -50,6 +50,3 @@
- name: backport:release/v2.1.x - name: backport:release/v2.1.x
description: To be backported to release/v2.1.x description: To be backported to release/v2.1.x
color: '#ffd700' color: '#ffd700'
- name: backport:release/v2.2.x
description: To be backported to release/v2.2.x
color: '#ffd700'

View File

@@ -5,17 +5,15 @@ The Flux ARM64 end-to-end tests run on Equinix Metal instances provisioned with
## Current instances ## Current instances
| Repository | Runner | Instance | Location | | Repository | Runner | Instance | Location |
|-----------------------------|------------------|----------------|---------------| |-----------------------------|------------------|------------------------|---------------|
| flux2 | equinix-arm-dc-1 | flux-arm-dc-01 | Washington DC | | flux2 | equinix-arm-dc-1 | flux-equinix-arm-dc-01 | Washington DC |
| flux2 | equinix-arm-dc-2 | flux-arm-dc-01 | Washington DC | | flux2 | equinix-arm-dc-2 | flux-equinix-arm-dc-01 | Washington DC |
| flux2 | equinix-arm-da-1 | flux-arm-da-01 | Dallas | | flux2 | equinix-arm-da-1 | flux-equinix-arm-da-01 | Dallas |
| flux2 | equinix-arm-da-2 | flux-arm-da-01 | Dallas | | flux2 | equinix-arm-da-2 | flux-equinix-arm-da-01 | Dallas |
| flux-benchmark | equinix-arm-dc-1 | flux-arm-dc-01 | Washington DC | | source-controller | equinix-arm-dc-1 | flux-equinix-arm-dc-01 | Washington DC |
| flux-benchmark | equinix-arm-da-1 | flux-arm-da-01 | Dallas | | source-controller | equinix-arm-da-1 | flux-equinix-arm-da-01 | Dallas |
| source-controller | equinix-arm-dc-1 | flux-arm-dc-01 | Washington DC | | image-automation-controller | equinix-arm-dc-1 | flux-equinix-arm-dc-01 | Washington DC |
| source-controller | equinix-arm-da-1 | flux-arm-da-01 | Dallas | | image-automation-controller | equinix-arm-da-1 | flux-equinix-arm-da-01 | Dallas |
| image-automation-controller | equinix-arm-dc-1 | flux-arm-dc-01 | Washington DC |
| image-automation-controller | equinix-arm-da-1 | flux-arm-da-01 | Dallas |
Instance spec: Instance spec:
- Ampere Altra Q80-30 80-core processor @ 2.8GHz - Ampere Altra Q80-30 80-core processor @ 2.8GHz

View File

@@ -18,11 +18,11 @@
set -eu set -eu
KIND_VERSION=0.22.0 KIND_VERSION=0.17.0
KUBECTL_VERSION=1.29.0 KUBECTL_VERSION=1.24.0
KUSTOMIZE_VERSION=5.3.0 KUSTOMIZE_VERSION=4.5.7
HELM_VERSION=3.14.1 HELM_VERSION=3.10.1
GITHUB_RUNNER_VERSION=2.313.0 GITHUB_RUNNER_VERSION=2.298.2
PACKAGES="apt-transport-https ca-certificates software-properties-common build-essential libssl-dev gnupg lsb-release jq pkg-config" PACKAGES="apt-transport-https ca-certificates software-properties-common build-essential libssl-dev gnupg lsb-release jq pkg-config"
# install prerequisites # install prerequisites

View File

@@ -22,7 +22,7 @@ RUNNER_NAME=$1
REPOSITORY_TOKEN=$2 REPOSITORY_TOKEN=$2
REPOSITORY_URL=${3:-https://github.com/fluxcd/flux2} REPOSITORY_URL=${3:-https://github.com/fluxcd/flux2}
GITHUB_RUNNER_VERSION=2.313.0 GITHUB_RUNNER_VERSION=2.298.2
# download runner # download runner
curl -o actions-runner-linux-arm64.tar.gz -L https://github.com/actions/runner/releases/download/v${GITHUB_RUNNER_VERSION}/actions-runner-linux-arm64-${GITHUB_RUNNER_VERSION}.tar.gz \ curl -o actions-runner-linux-arm64.tar.gz -L https://github.com/actions/runner/releases/download/v${GITHUB_RUNNER_VERSION}/actions-runner-linux-arm64-${GITHUB_RUNNER_VERSION}.tar.gz \

View File

@@ -135,7 +135,7 @@ func init() {
bootstrapCmd.PersistentFlags().StringVar(&bootstrapArgs.commitMessageAppendix, "commit-message-appendix", "", "string to add to the commit messages, e.g. '[ci skip]'") bootstrapCmd.PersistentFlags().StringVar(&bootstrapArgs.commitMessageAppendix, "commit-message-appendix", "", "string to add to the commit messages, e.g. '[ci skip]'")
bootstrapCmd.PersistentFlags().BoolVar(&bootstrapArgs.force, "force", false, "override existing Flux installation if it's managed by a different tool such as Helm") bootstrapCmd.PersistentFlags().BoolVar(&bootstrapArgs.force, "force", false, "override existing Flux installation if it's managed by a diffrent tool such as Helm")
bootstrapCmd.PersistentFlags().MarkHidden("manifests") bootstrapCmd.PersistentFlags().MarkHidden("manifests")
rootCmd.AddCommand(bootstrapCmd) rootCmd.AddCommand(bootstrapCmd)

View File

@@ -102,7 +102,7 @@ func init() {
installCmd.Flags().StringVar(&installArgs.clusterDomain, "cluster-domain", rootArgs.defaults.ClusterDomain, "internal cluster domain") installCmd.Flags().StringVar(&installArgs.clusterDomain, "cluster-domain", rootArgs.defaults.ClusterDomain, "internal cluster domain")
installCmd.Flags().StringSliceVar(&installArgs.tolerationKeys, "toleration-keys", nil, installCmd.Flags().StringSliceVar(&installArgs.tolerationKeys, "toleration-keys", nil,
"list of toleration keys used to schedule the components pods onto nodes with matching taints") "list of toleration keys used to schedule the components pods onto nodes with matching taints")
installCmd.Flags().BoolVar(&installArgs.force, "force", false, "override existing Flux installation if it's managed by a different tool such as Helm") installCmd.Flags().BoolVar(&installArgs.force, "force", false, "override existing Flux installation if it's managed by a diffrent tool such as Helm")
installCmd.Flags().MarkHidden("manifests") installCmd.Flags().MarkHidden("manifests")
rootCmd.AddCommand(installCmd) rootCmd.AddCommand(installCmd)

View File

@@ -103,7 +103,7 @@ func WithTimeout(timeout time.Duration) BuilderOptionFunc {
func WithProgressBar() BuilderOptionFunc { func WithProgressBar() BuilderOptionFunc {
return func(b *Builder) error { return func(b *Builder) error {
// Add a spinner // Add a spiner
cfg := yacspin.Config{ cfg := yacspin.Config{
Frequency: 100 * time.Millisecond, Frequency: 100 * time.Millisecond,
CharSet: yacspin.CharSets[59], CharSet: yacspin.CharSets[59],
@@ -361,7 +361,7 @@ func (b *Builder) generate(kustomization kustomizev1.Kustomization, dirPath stri
} }
// a scanner will be used down the line to parse the list // a scanner will be used down the line to parse the list
// so we have to make sure to include newlines // so we have to make sure to unclude newlines
ignoreList := strings.Join(b.ignore, "\n") ignoreList := strings.Join(b.ignore, "\n")
gen := kustomize.NewGeneratorWithIgnore("", ignoreList, unstructured.Unstructured{Object: data}) gen := kustomize.NewGeneratorWithIgnore("", ignoreList, unstructured.Unstructured{Object: data})
@@ -375,7 +375,7 @@ func (b *Builder) generate(kustomization kustomizev1.Kustomization, dirPath stri
func (b *Builder) do(ctx context.Context, kustomization kustomizev1.Kustomization, dirPath string) (resmap.ResMap, error) { func (b *Builder) do(ctx context.Context, kustomization kustomizev1.Kustomization, dirPath string) (resmap.ResMap, error) {
fs := filesys.MakeFsOnDisk() fs := filesys.MakeFsOnDisk()
// acquire the lock // acuire the lock
b.mu.Lock() b.mu.Lock()
defer b.mu.Unlock() defer b.mu.Unlock()
@@ -562,9 +562,9 @@ func maskSopsDataInStringDataSecret(stringDataMap map[string]string, mask string
} }
// Cancel cancels the build // Cancel cancels the build
// It restores a clean repository // It restores a clean reprository
func (b *Builder) Cancel() error { func (b *Builder) Cancel() error {
// acquire the lock // acuire the lock
b.mu.Lock() b.mu.Lock()
defer b.mu.Unlock() defer b.mu.Unlock()

View File

@@ -1,15 +1,13 @@
# :warning: Removal Notice # :warning: Deprecation Notice
Starting Flux v2.1.0, released August 24, 2023, the Flux monitoring Starting Flux v2.1.0, released August 24, 2023, the Flux monitoring
configurations in this repository were marked as deprecated. The new monitoring configurations in this repository will be marked as deprecated. New monitoring
docs are available at [Flux monitoring](https://fluxcd.io/flux/monitoring/) docs are available at [Flux monitoring](https://fluxcd.io/flux/monitoring/)
docs with new example configurations in docs with new example configurations in
[fluxcd/flux2-monitoring-example](https://github.com/fluxcd/flux2-monitoring-example/). [fluxcd/flux2-monitoring-example](https://github.com/fluxcd/flux2-monitoring-example/).
The deprecated configurations will be removed in a future release of Flux. All
The deprecated configurations were removed in Flux v2.2 on December 13, 2023. All users of these configurations are recommended to use the new monitoring setup,
users of these configurations are advised to use the new monitoring setup, following the docs and the new examples.
following the [docs](https://fluxcd.io/flux/monitoring/) and the
[examples](https://github.com/fluxcd/flux2-monitoring-example/).
After collecting a lot of user feedback about our monitoring recommendation, in After collecting a lot of user feedback about our monitoring recommendation, in
order to serve most of the needs of the users, we decided to create a new order to serve most of the needs of the users, we decided to create a new

View File

@@ -0,0 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: monitoring
resources:
- namespace.yaml
- repository.yaml
- release.yaml

View File

@@ -0,0 +1,6 @@
apiVersion: v1
kind: Namespace
metadata:
name: monitoring
labels:
app.kubernetes.io/component: monitoring

View File

@@ -0,0 +1,51 @@
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: kube-prometheus-stack
spec:
interval: 5m
chart:
spec:
version: "45.x"
chart: kube-prometheus-stack
sourceRef:
kind: HelmRepository
name: prometheus-community
interval: 60m
install:
crds: Create
upgrade:
crds: CreateReplace
# https://github.com/prometheus-community/helm-charts/blob/main/charts/kube-prometheus-stack/values.yaml
values:
alertmanager:
enabled: false
prometheus:
prometheusSpec:
retention: 24h
resources:
requests:
cpu: 200m
memory: 200Mi
podMonitorNamespaceSelector: {}
podMonitorSelector:
matchLabels:
app.kubernetes.io/component: monitoring
postRenderers:
- kustomize:
patches:
- target:
# Ignore these objects from Flux diff as they are mutated from chart hooks
kind: (ValidatingWebhookConfiguration|MutatingWebhookConfiguration)
name: kube-prometheus-stack-admission
patch: |
- op: add
path: /metadata/annotations/helm.toolkit.fluxcd.io~1driftDetection
value: disabled
- target:
# Ignore these objects from Flux diff as they are mutated at apply time but not at dry-run time
kind: PrometheusRule
patch: |
- op: add
path: /metadata/annotations/helm.toolkit.fluxcd.io~1driftDetection
value: disabled

View File

@@ -0,0 +1,9 @@
apiVersion: source.toolkit.fluxcd.io/v1beta2
kind: HelmRepository
metadata:
name: prometheus-community
spec:
interval: 120m
# OCI builds for kube-prometheus-stack have been temporarily disabled (see https://github.com/prometheus-community/helm-charts/issues/2940).
type: default
url: https://prometheus-community.github.io/helm-charts

View File

@@ -0,0 +1,6 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: monitoring
resources:
- repository.yaml
- release.yaml

View File

@@ -0,0 +1,40 @@
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
name: loki-stack
spec:
interval: 5m
dependsOn:
- name: kube-prometheus-stack
chart:
spec:
version: "2.x"
chart: loki-stack
sourceRef:
kind: HelmRepository
name: grafana-charts
interval: 60m
# https://github.com/grafana/helm-charts/blob/main/charts/loki-stack/values.yaml
# https://github.com/grafana/loki/blob/main/production/helm/loki/values.yaml
values:
grafana:
enabled: false
sidecar:
datasources:
enabled: true
maxLines: 1000
promtail:
enabled: true
loki:
enabled: true
isDefault: false
serviceMonitor:
enabled: true
additionalLabels:
app.kubernetes.io/part-of: kube-prometheus-stack
config:
chunk_store_config:
max_look_back_period: 0s
table_manager:
retention_deletes_enabled: true
retention_period: 12h

View File

@@ -0,0 +1,7 @@
apiVersion: source.toolkit.fluxcd.io/v1beta2
kind: HelmRepository
metadata:
name: grafana-charts
spec:
interval: 120m0s
url: https://grafana.github.io/helm-charts

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,332 @@
{
"__inputs": [
{
"name": "DS_LOKI",
"label": "Loki",
"description": "",
"type": "datasource",
"pluginId": "loki",
"pluginName": "Loki"
}
],
"annotations": {
"list": [
{
"builtIn": 1,
"datasource": "-- Grafana --",
"enable": true,
"hide": true,
"iconColor": "rgba(0, 211, 255, 1)",
"name": "Annotations & Alerts",
"target": {
"limit": 100,
"matchAny": false,
"tags": [],
"type": "dashboard"
},
"type": "dashboard"
},
{
"datasource": {
"type": "datasource",
"uid": "grafana"
},
"enable": true,
"iconColor": "red",
"name": "flux events",
"target": {
"limit": 100,
"matchAny": false,
"tags": [
"flux"
],
"type": "tags"
}
}
]
},
"description": "Flux logs collected from Kubernetes, stored in Loki",
"editable": true,
"gnetId": null,
"graphTooltip": 0,
"id": 29,
"iteration": 1653748775696,
"links": [],
"liveNow": false,
"panels": [
{
"datasource": "${DS_LOKI}",
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "bars",
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "auto",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
},
{
"color": "red",
"value": 80
}
]
}
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 24,
"x": 0,
"y": 0
},
"id": 4,
"options": {
"legend": {
"calcs": [],
"displayMode": "hidden",
"placement": "bottom"
},
"tooltip": {
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": "${DS_LOKI}",
"expr": "sum(count_over_time({namespace=~\"$namespace\", stream=~\"$stream\", app =~\"$controller\"} | json | __error__!=\"JSONParserErr\" | level=~\"$level\" |= \"$query\" [$__interval]))",
"instant": false,
"legendFormat": "Log count",
"range": true,
"refId": "A"
}
],
"type": "timeseries"
},
{
"datasource": "${DS_LOKI}",
"description": "Logs from services running in Kubernetes",
"gridPos": {
"h": 25,
"w": 24,
"x": 0,
"y": 4
},
"id": 2,
"options": {
"dedupStrategy": "numbers",
"enableLogDetails": false,
"prettifyLogMessage": true,
"showCommonLabels": false,
"showLabels": false,
"showTime": false,
"sortOrder": "Descending",
"wrapLogMessage": false
},
"targets": [
{
"datasource": "${DS_LOKI}",
"expr": "{namespace=~\"$namespace\", stream=~\"$stream\", app =~\"$controller\"} | json | __error__!=\"JSONParserErr\" | level=~\"$level\" |= \"$query\"",
"refId": "A"
}
],
"type": "logs"
}
],
"refresh": "10s",
"schemaVersion": 36,
"style": "light",
"tags": [
"flux"
],
"templating": {
"list": [
{
"current": {
"selected": false,
"text": "",
"value": ""
},
"description": "String to search for",
"hide": 0,
"label": "Search Query",
"name": "query",
"options": [
{
"selected": true,
"text": "",
"value": ""
}
],
"query": "",
"skipUrlSync": false,
"type": "textbox"
},
{
"allValue": "info|error",
"current": {
"selected": false,
"text": "All",
"value": "$__all"
},
"hide": 0,
"includeAll": true,
"multi": false,
"name": "level",
"options": [
{
"selected": true,
"text": "All",
"value": "$__all"
},
{
"selected": false,
"text": "info",
"value": "info"
},
{
"selected": false,
"text": "error",
"value": "error"
}
],
"query": "info,error",
"queryValue": "",
"skipUrlSync": false,
"type": "custom"
},
{
"allValue": ".+",
"current": {
"selected": true,
"text": [
"All"
],
"value": [
"$__all"
]
},
"datasource": "${DS_LOKI}",
"definition": "label_values(app)",
"hide": 0,
"includeAll": true,
"multi": true,
"name": "controller",
"options": [],
"query": "label_values(app)",
"refresh": 1,
"regex": "",
"skipUrlSync": false,
"sort": 0,
"type": "query"
},
{
"allValue": ".+",
"current": {
"selected": true,
"text": [
"flux-system"
],
"value": [
"flux-system"
]
},
"datasource": "${DS_LOKI}",
"definition": "label_values(namespace)",
"hide": 0,
"includeAll": true,
"multi": true,
"name": "namespace",
"options": [],
"query": "label_values(namespace)",
"refresh": 1,
"regex": "",
"skipUrlSync": false,
"sort": 0,
"type": "query"
},
{
"allValue": ".+",
"current": {
"selected": false,
"text": "All",
"value": "$__all"
},
"datasource": "${DS_LOKI}",
"definition": "label_values(stream)",
"hide": 0,
"includeAll": true,
"multi": true,
"name": "stream",
"options": [],
"query": "label_values(stream)",
"refresh": 1,
"regex": "",
"skipUrlSync": false,
"sort": 0,
"type": "query"
},
{
"current": {
"selected": false,
"text": "Loki",
"value": "Loki"
},
"hide": 0,
"includeAll": false,
"label": "Datasource",
"multi": false,
"name": "DS_LOKI",
"options": [],
"query": "loki",
"refresh": 1,
"regex": "",
"skipUrlSync": false,
"type": "datasource"
}
]
},
"time": {
"from": "now-6h",
"to": "now"
},
"timepicker": {},
"timezone": "",
"title": "Flux Logs",
"uid": "flux-logs",
"version": 2
}

View File

@@ -0,0 +1,16 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
namespace: monitoring
resources:
- podmonitor.yaml
configMapGenerator:
- name: flux-grafana-dashboards
files:
- dashboards/control-plane.json
- dashboards/cluster.json
- dashboards/logs.json
options:
labels:
grafana_dashboard: "1"
app.kubernetes.io/part-of: flux
app.kubernetes.io/component: monitoring

View File

@@ -0,0 +1,30 @@
apiVersion: monitoring.coreos.com/v1
kind: PodMonitor
metadata:
name: flux-system
namespace: flux-system
labels:
app.kubernetes.io/part-of: flux
app.kubernetes.io/component: monitoring
spec:
namespaceSelector:
matchNames:
- flux-system
selector:
matchExpressions:
- key: app
operator: In
values:
- helm-controller
- source-controller
- kustomize-controller
- notification-controller
- image-automation-controller
- image-reflector-controller
podMetricsEndpoints:
- port: http-prom
relabelings:
# https://github.com/prometheus-operator/prometheus-operator/issues/4816
- sourceLabels: [__meta_kubernetes_pod_phase]
action: keep
regex: Running

Binary file not shown.

Before

Width:  |  Height:  |  Size: 177 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 731 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 39 KiB

View File

@@ -1,134 +0,0 @@
# Flux CDEvents Receiver
<!--
The title must be short and descriptive.
-->
**Status:** provisional
<!--
Status represents the current state of the RFC.
Must be one of `provisional`, `implementable`, `implemented`, `deferred`, `rejected`, `withdrawn`, or `replaced`.
-->
**Creation date:** 2023-12-08
**Last update:** 2024-02-09
## Summary
The CDEvents Receiver for Flux receives a CDEvent sent to the receiver webhook URL, verifies it and checks the event type against `.spec.events`, then triggers reconciliation of the configured resources.
<!--
One paragraph explanation of the proposed feature or enhancement.
-->
## Motivation
CDEvents enables interoperability between supported tools in a workflow, and flux is a very popular continuous delivery tool, as such we have received many questions about implementing CDEvents into the tool.
<!--
This section is for explicitly listing the motivation, goals, and non-goals of
this RFC. Describe why the change is important and the benefits to users.
-->
### Goals
Integrate CDEvents into Flux with a CDEvents Receiver.
<!--
List the specific goals of this RFC. What is it trying to achieve? How will we
know that this has succeeded?
-->
### Non-Goals
A CDEvent provider will be handled as a separate RFC in the future.
<!--
What is out of scope for this RFC? Listing non-goals helps to focus discussion
and make progress.
-->
## Proposal
Add CDEvents to the list of available receivers in Flux Notification controller. Similar to other receivers such as the github, the user will be able to use `spec.events` in order to specify which event types the receiver will allow. The receiver will also verify using the [CDEvents Go SDK](https://github.com/cdevents/sdk-go) that the payload sent to the webhook URL is a valid CDEvent.
<!--
This is where we get down to the specifics of what the proposal actually is.
This should have enough detail that reviewers can understand exactly what
you're proposing, but should not include things like API designs or
implementation.
If the RFC goal is to document best practices,
then this section can be replaced with the actual documentation.
-->
### User Stories
<!--
Optional if existing discussions and/or issues are linked in the motivation section.
-->
Using Tekton the user triggers something that will fire off a CDEvent to the CloudEvents Broker. A subscription that the user will have set up externally will then send a relevant CDEvent to the CDEvent Receiver within Flux based on the configuration.
![usecase](cdevents-flux-tekton.png)
### Alternatives
Certain use cases for CDEvents could be done alternatively using available receivers such as the generic webhook.
<!--
List plausible alternatives to the proposal and explain why the proposal is superior.
This is a good place to incorporate suggestions made during discussion of the RFC.
-->
## Design Details
Adding a receiver for CDEvents that works much like the other event-based receivers already implemented. The user will be able to write a yaml file for the receiver and deploy it to their cluster. The receiver takes the payload sent to the webhook URL by an external events broker, checks the headers for the event type, and filters out events based on the user-defined list of events in spec.Events. If left empty, it will act on all valid CDEvents. It then validates the payload body using the [CDEvents Go SDK](https://github.com/cdevents/sdk-go). Valid events will then trigger reconciliation of the resources. The events broker is not a part of this design and is left to the user to set up however they wish.
Example Receiver YAML:
```yaml
apiVersion: notification.toolkit.fluxcd.io/v1
kind: Receiver
metadata:
name: cdevents-receiver
namespace: flux-system
spec:
type: cdevents
events:
- "dev.cdevents.change.merged"
secretRef:
name: receiver-token
resources:
- kind: GitRespository
apiVersion: source.toolkit.fluxcd.io/v1
name: webapp
namespace: flux-system
```
![User Flowchart](Flux-CDEvents-RFC.png)
<!--
This section should contain enough information that the specifics of your
change are understandable. This may include API specs and code snippets.
The design details should address at least the following questions:
- How can this feature be enabled / disabled?
- Does enabling the feature change any default behavior?
- Can the feature be disabled once it has been enabled?
- How can an operator determine if the feature is in use?
- Are there any drawbacks when enabling this feature?
-->
![Adapter](CDEvents-Flux-RFC-Adapter.png)
## Implementation History
<!--
Major milestones in the lifecycle of the RFC such as:
- The first Flux release where an initial version of the RFC was available.
- The version of Flux where the RFC graduated to general availability.
- The version of Flux where the RFC was retired or superseded.
-->

Binary file not shown.

Before

Width:  |  Height:  |  Size: 649 KiB

View File

@@ -17,14 +17,6 @@ test-azure:
test-gcp: test-gcp:
$(MAKE) test PROVIDER_ARG="-provider gcp" $(MAKE) test PROVIDER_ARG="-provider gcp"
destroy:
go test -timeout $(TEST_TIMEOUT) -v ./ $(GO_TEST_ARGS) $(PROVIDER_ARG) -destroy-only
destroy-azure:
$(MAKE) destroy PROVIDER_ARG="-provider azure"
destroy-gcp:
$(MAKE) destroy PROVIDER_ARG="-provider gcp"
sops-check: sops-check:
ifeq ($(shell which sops),) ifeq ($(shell which sops),)

View File

@@ -74,10 +74,6 @@ variables using
use the terraform configuration below. Please make sure all the requirements of use the terraform configuration below. Please make sure all the requirements of
azure-gh-actions are followed before running it. azure-gh-actions are followed before running it.
**NOTE:** When running the following for a repo under an organization, set the
environment variable `GITHUB_ORGANIZATION` if setting the `owner` in the
`github` provider doesn't work.
```hcl ```hcl
provider "github" { provider "github" {
owner = "fluxcd" owner = "fluxcd"
@@ -222,7 +218,7 @@ variables using
use the terraform configuration below. Please make sure all the requirements of use the terraform configuration below. Please make sure all the requirements of
gcp-gh-actions are followed before running it. gcp-gh-actions are followed before running it.
**NOTE:** When running the following for a repo under an organization, set the **NOTE:** When running the following for a repo under and organization, set the
environment variable `GITHUB_ORGANIZATION` if setting the `owner` in the environment variable `GITHUB_ORGANIZATION` if setting the `owner` in the
`github` provider doesn't work. `github` provider doesn't work.
@@ -349,13 +345,8 @@ We also pull two version of `ghcr.io/stefanprodan/podinfo` image. These images a
Container Registry and used to test `ImageRepository` and `ImageUpdateAutomation`. The terraform resources get created Container Registry and used to test `ImageRepository` and `ImageUpdateAutomation`. The terraform resources get created
and the tests are run. and the tests are run.
If not configured explicitly to retain the infrastructure, at the end of the **IMPORTANT:** In case the terraform infrastructure results in a bad state, maybe due to a crash during the apply,
test, the test infrastructure is deleted. In case of any failure due to which the whole infrastructure can be destroyed by running terraform destroy in terraform/<provider> directory.
the resources don't get deleted, the `make destroy-*` commands can be run for
the respective provider. This will run terraform destroy in the respective
provider's terraform configuration directory. This can be used to quickly
destroy the infrastructure without going through the provision-test-destroy
steps.
### Debugging the tests ### Debugging the tests

View File

@@ -20,7 +20,6 @@ require (
github.com/fluxcd/test-infra/tftestenv v0.0.0-20240108135005-b58e0c4e0cfa github.com/fluxcd/test-infra/tftestenv v0.0.0-20240108135005-b58e0c4e0cfa
github.com/go-git/go-git/v5 v5.11.0 github.com/go-git/go-git/v5 v5.11.0
github.com/google/go-containerregistry v0.19.0 github.com/google/go-containerregistry v0.19.0
github.com/hashicorp/terraform-exec v0.18.1
github.com/hashicorp/terraform-json v0.16.0 github.com/hashicorp/terraform-json v0.16.0
github.com/microsoft/azure-devops-go-api/azuredevops v1.0.0-b5 github.com/microsoft/azure-devops-go-api/azuredevops v1.0.0-b5
github.com/onsi/gomega v1.31.1 github.com/onsi/gomega v1.31.1
@@ -90,6 +89,7 @@ require (
github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/hashicorp/go-version v1.6.0 // indirect github.com/hashicorp/go-version v1.6.0 // indirect
github.com/hashicorp/hc-install v0.5.0 // indirect github.com/hashicorp/hc-install v0.5.0 // indirect
github.com/hashicorp/terraform-exec v0.18.1 // indirect
github.com/imdario/mergo v0.3.16 // indirect github.com/imdario/mergo v0.3.16 // indirect
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect
github.com/josharian/intern v1.0.0 // indirect github.com/josharian/intern v1.0.0 // indirect

View File

@@ -26,7 +26,6 @@ import (
"testing" "testing"
"time" "time"
"github.com/hashicorp/terraform-exec/tfexec"
tfjson "github.com/hashicorp/terraform-json" tfjson "github.com/hashicorp/terraform-json"
utilruntime "k8s.io/apimachinery/pkg/util/runtime" utilruntime "k8s.io/apimachinery/pkg/util/runtime"
"k8s.io/client-go/kubernetes/scheme" "k8s.io/client-go/kubernetes/scheme"
@@ -198,20 +197,6 @@ func TestMain(m *testing.M) {
log.Fatalf("Failed to get provider config for %q", infraOpts.Provider) log.Fatalf("Failed to get provider config for %q", infraOpts.Provider)
} }
// Run destroy-only mode if enabled.
if infraOpts.DestroyOnly {
log.Println("Running in destroy-only mode...")
envOpts := []tftestenv.EnvironmentOption{
tftestenv.WithVerbose(infraOpts.Verbose),
// Ignore any state lock in destroy-only mode.
tftestenv.WithTfDestroyOptions(tfexec.Lock(false)),
}
if err := tftestenv.Destroy(ctx, providerCfg.terraformPath, envOpts...); err != nil {
panic(err)
}
os.Exit(0)
}
// Initialize with non-zero exit code to indicate failure by default unless // Initialize with non-zero exit code to indicate failure by default unless
// set by a successful test run. // set by a successful test run.
exitCode := 1 exitCode := 1