-
Notifications
You must be signed in to change notification settings - Fork 1
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
[pull] master from spinnaker:master #52
base: master
Are you sure you want to change the base?
Conversation
* fix(npe): Fixes an NPE when no overrides are set * chore(nullable): Add nullable annotation as well to signify overides can be null
PR title: Reason: Because we enforce conventional commits and squash merges of PRs, the PR Title becomes the commit title.
For more information, see the Conventional Commits specification. Some common examples are:
|
Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2 to 3. - [Release notes](https://github.com/docker/setup-buildx-action/releases) - [Commits](docker/setup-buildx-action@v2...v3) --- updated-dependencies: - dependency-name: docker/setup-buildx-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [docker/login-action](https://github.com/docker/login-action) from 2 to 3. - [Release notes](https://github.com/docker/login-action/releases) - [Commits](docker/login-action@v2...v3) --- updated-dependencies: - dependency-name: docker/login-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 2 to 3. - [Release notes](https://github.com/docker/setup-qemu-action/releases) - [Commits](docker/setup-qemu-action@v2...v3) --- updated-dependencies: - dependency-name: docker/setup-qemu-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](actions/checkout@v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4 to 5. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](docker/build-push-action@v4...v5) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: root <root@997746f94e50>
Co-authored-by: root <root@7a34ebc50f11>
…ails of the APIs versions (#1020) * security(feature): Change codeql to scan daily instead of weekly * feat(helm/bake): Add additional input fields where we can fill in details of the APIs versions - These input fields will not be pre-populated with versions of the target cluster available in the environment. - They will become part of the bake result. - Added API_VERSIONS_ENABLED env variable flag * feat(helm/bake): Add additional input fields where we can fill in details of the APIs versions - These input fields will not be pre-populated with versions of the target cluster available in the environment. - They will become part of the bake result. - Added API_VERSIONS_ENABLED env variable flag * feat(helm/bake): Add additional input fields where we can fill in details of the APIs versions - These input fields will not be pre-populated with versions of the target cluster available in the environment. - They will become part of the bake result. - Added API_VERSIONS_ENABLED env variable flag --------- Co-authored-by: Jason McIntosh <[email protected]>
Co-authored-by: root <root@0c89bc74b80c>
…with upgrade of groovy 3 (#1032)
Co-authored-by: root <root@2622b4f2d1ae>
* chore(dependencies): Autobump korkVersion * fix(manifests/test): keep up with SpinnakerNetworkException constructor changes from spinnaker/kork#1110 --------- Co-authored-by: root <root@2f91e8016c3c> Co-authored-by: David Byron <[email protected]>
Co-authored-by: root <root@b43cc05aaab3>
Co-authored-by: root <root@ed8952ab89fc>
Co-authored-by: root <root@1d3c5d772f3e>
Co-authored-by: root <root@d2232a6b7721>
Co-authored-by: root <root@d6fbaf65e488>
Co-authored-by: root <root@140f03da0671>
Co-authored-by: root <root@b9d4fd4a0e9b>
Co-authored-by: root <root@37eec47d8cd2>
since spinnaker/kork#1120 removes the artifact-store.enabled property such that ArtifactStore beans are always present.
Co-authored-by: root <root@18f17eebc378>
Co-authored-by: root <root@d877509078f3>
Bumps [google-github-actions/auth](https://github.com/google-github-actions/auth) from 1 to 2. - [Release notes](https://github.com/google-github-actions/auth/releases) - [Changelog](https://github.com/google-github-actions/auth/blob/main/CHANGELOG.md) - [Commits](google-github-actions/auth@v1...v2) --- updated-dependencies: - dependency-name: google-github-actions/auth dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [actions/setup-java](https://github.com/actions/setup-java) from 3 to 4. - [Release notes](https://github.com/actions/setup-java/releases) - [Commits](actions/setup-java@v3...v4) --- updated-dependencies: - dependency-name: actions/setup-java dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: root <root@daf8138033e1>
Co-authored-by: root <root@51dce6428a99>
Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 5 to 6. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](docker/build-push-action@v5...v6) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: root <root@de6989adb87f>
Co-authored-by: root <root@35d9e249176d>
Co-authored-by: root <root@6fca7a9c2849>
Co-authored-by: root <root@ab7e4966783c>
….0 (#1102) While upgrading junit to 5.9.0, encountered below error during test execution of rosco-web and rosco-manifests module: ``` @beforeeach method 'private void com.netflix.spinnaker.rosco.controllers.V2BakeryControllerTest.init(org.junit.jupiter.api.TestInfo)' must not be private. org.junit.platform.commons.JUnitException: @beforeeach method 'private void com.netflix.spinnaker.rosco.controllers.V2BakeryControllerTest.init(org.junit.jupiter.api.TestInfo)' must not be private. at org.junit.jupiter.engine.descriptor.LifecycleMethodUtils.assertNonPrivate(LifecycleMethodUtils.java:104) at org.junit.jupiter.engine.descriptor.LifecycleMethodUtils.lambda$findMethodsAndAssertNonStaticAndNonPrivate$2(LifecycleMethodUtils.java:74) at java.base/java.util.ArrayList.forEach(ArrayList.java:1511) at java.base/java.util.Collections$UnmodifiableCollection.forEach(Collections.java:1092) at org.junit.jupiter.engine.descriptor.LifecycleMethodUtils.findMethodsAndAssertNonStaticAndNonPrivate(LifecycleMethodUtils.java:72) at org.junit.jupiter.engine.descriptor.LifecycleMethodUtils.findBeforeEachMethods(LifecycleMethodUtils.java:50) at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.registerBeforeEachMethodAdapters(ClassBasedTestDescriptor.java:478) at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.prepare(ClassBasedTestDescriptor.java:174) at org.junit.jupiter.engine.descriptor.ClassBasedTestDescriptor.prepare(ClassBasedTestDescriptor.java:84) at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$prepare$2(NodeTestTask.java:123) at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73) at org.junit.platform.engine.support.hierarchical.NodeTestTask.prepare(NodeTestTask.java:123) at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:90) at java.base/java.util.ArrayList.forEach(ArrayList.java:1511) at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.invokeAll(SameThreadHierarchicalTestExecutorService.java:41) at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$6(NodeTestTask.java:155) at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73) at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$8(NodeTestTask.java:141) at org.junit.platform.engine.support.hierarchical.Node.around(Node.java:137) at org.junit.platform.engine.support.hierarchical.NodeTestTask.lambda$executeRecursively$9(NodeTestTask.java:139) at org.junit.platform.engine.support.hierarchical.ThrowableCollector.execute(ThrowableCollector.java:73) at org.junit.platform.engine.support.hierarchical.NodeTestTask.executeRecursively(NodeTestTask.java:138) at org.junit.platform.engine.support.hierarchical.NodeTestTask.execute(NodeTestTask.java:95) at org.junit.platform.engine.support.hierarchical.SameThreadHierarchicalTestExecutorService.submit(SameThreadHierarchicalTestExecutorService.java:35) at org.junit.platform.engine.support.hierarchical.HierarchicalTestExecutor.execute(HierarchicalTestExecutor.java:57) at org.junit.platform.engine.support.hierarchical.HierarchicalTestEngine.execute(HierarchicalTestEngine.java:54) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:147) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:127) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:90) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.lambda$execute$0(EngineExecutionOrchestrator.java:55) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.withInterceptedStreams(EngineExecutionOrchestrator.java:102) at org.junit.platform.launcher.core.EngineExecutionOrchestrator.execute(EngineExecutionOrchestrator.java:54) at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:114) at org.junit.platform.launcher.core.DefaultLauncher.execute(DefaultLauncher.java:86) at org.junit.platform.launcher.core.DefaultLauncherSession$DelegatingLauncher.execute(DefaultLauncherSession.java:86) at org.junit.platform.launcher.core.SessionPerRequestLauncher.execute(SessionPerRequestLauncher.java:53) at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.processAllTestClasses(JUnitPlatformTestClassProcessor.java:99) at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor$CollectAllTestClassesExecutor.access$000(JUnitPlatformTestClassProcessor.java:79) at org.gradle.api.internal.tasks.testing.junitplatform.JUnitPlatformTestClassProcessor.stop(JUnitPlatformTestClassProcessor.java:75) at org.gradle.api.internal.tasks.testing.SuiteTestClassProcessor.stop(SuiteTestClassProcessor.java:62) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:568) at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:36) at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24) at org.gradle.internal.dispatch.ContextClassLoaderDispatch.dispatch(ContextClassLoaderDispatch.java:33) at org.gradle.internal.dispatch.ProxyDispatchAdapter$DispatchingInvocationHandler.invoke(ProxyDispatchAdapter.java:94) at jdk.proxy1/jdk.proxy1.$Proxy2.stop(Unknown Source) at org.gradle.api.internal.tasks.testing.worker.TestWorker$3.run(TestWorker.java:193) at org.gradle.api.internal.tasks.testing.worker.TestWorker.executeAndMaintainThreadName(TestWorker.java:129) at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:100) at org.gradle.api.internal.tasks.testing.worker.TestWorker.execute(TestWorker.java:60) at org.gradle.process.internal.worker.child.ActionExecutionWorker.execute(ActionExecutionWorker.java:56) at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:113) at org.gradle.process.internal.worker.child.SystemApplicationClassLoaderWorker.call(SystemApplicationClassLoaderWorker.java:65) at worker.org.gradle.process.internal.worker.GradleWorkerMain.run(GradleWorkerMain.java:69) at worker.org.gradle.process.internal.worker.GradleWorkerMain.main(GradleWorkerMain.java:74) ``` The root cause of this issue is breaking change brought in 5.9.0 to private lifecycle methods (annotated with @BeforeAll, @afterall, @beforeeach, or @AfterEach) leading to an exception. https://junit.org/junit5/docs/5.9.0/release-notes/index.html#deprecations-and-breaking-changes-2 To fix this issue changed the scope of init method from private to generic.
Co-authored-by: root <root@7e5a124a1944>
Co-authored-by: root <root@31d6695ca59c>
Co-authored-by: root <root@c9835c7522f6>
* chore(dependencies): Autobump korkVersion * refactor(dependency): replace groovy coordinates during upgrade of groovy 4.x Replacing the groovy coordinates from `org.codehaus.groovy` to `org.apache.groovy` supported by groovy 4.x and above versions. While upgrading groovy 4.0.15, encounter below error during build process of rosco-core module: ``` startup failed: /rosco/rosco-core/src/main/groovy/com/netflix/spinnaker/rosco/api/BakeRequest.groovy: -1: Access to java.lang.Object#request_id is forbidden @ line -1, column -1. 1 error > Task :rosco-core:compileGroovy FAILED ``` In order to make `request_id` accessible, removed `final` access specifier and updated the deprecated `ApiModelProperty.readOnly()` method with `ApiModelProperty.AccessMode()` [method](https://docs.swagger.io/swagger-core/v1.5.X/apidocs/io/swagger/annotations/ApiModelProperty.html#readOnly()). --------- Co-authored-by: root <root@b3e368603f7c> Co-authored-by: j-sandy <[email protected]>
Co-authored-by: root <root@84926203b695>
Co-authored-by: root <root@0e8a9747aac9>
Co-authored-by: root <root@76e4fcc2b807>
Co-authored-by: root <root@b2d607896795>
Co-authored-by: root <root@c407cd7c4eac>
* chore(java): Full Java 17 support only * chore(java): Full Java 17 support only * chore(java): Full Java 17 support only
Co-authored-by: root <root@f15c9eb9818b>
Co-authored-by: root <root@7a9eafb286db>
…te pre/post 1.1.2 plugin (#1122)
* fix(openapi): Rewrite Swagger to OpenAPI annotations * chore(deps): bump latest kork version --------- Co-authored-by: Edgar Garcia <[email protected]>
Co-authored-by: root <root@935cb5015720>
* test(core): demonstrate current behavior of JobExecutorLocal with empty output This test currently fails. The next commit fixes it. * fix(core): prevent null outputContent in the BakeStatus that JobExecutorLocal.updateStatus returns. Before this change, if the output of e.g. helm template is an empty string, the BakeStatus object that JobExecutorLocal.updateStatus returns is null, and HelmTemplateUtils.removeTestsDirectoryTemplates throws a NullPointerException. HelmBakeManifestService.bake calls BakeManifestService.doBake which calls JobExecutorLocal.updateStatus, and then HelmBakeManifestService.bake calls HelmTemplateUtils.removeTestsDirectoryTemplates with the resulting String. With this change, removeTestsDirectoryTemplates gets an empty string, and so the bake manifest endpoint (e.g. POST /api/v2/manifest/bake/helm) returns an empty Artifact. Without a corresponding change to clouddriver to handle a null KubernetesManifest, there's still a clouddriver crash in a deploy manifest that consumes the output of this bake, but it's progress.
Co-authored-by: root <root@d6aa4183a5bc>
* fix(helm): teach rosco to write helm overrides to a file The goal is to address an error in HelmTemplateUtils that occurs when the command line becomes too long due to a large number of overrides. The solution is to introduce a configurable threshold. If the overrides exceed this threshold, write them to a file and use the --values option when invoking Helm. The default behaviour (threshold of 0) retains the current approach of not using a file, regardless of the size of the overrides. * fix(helm): move `--values` argument for overrides to the end of the helm template command line ensure override precedence in helm template by appending --values with overrides at the command end, as --set/--set-string override --values in Helm 2.16.1 and 3.4.1, and later --values take highest precedence * fix(manifests): when writing overrides to a file, expand artifact reference URIs if configured to do so * fix(helm) : handle overrides with nested keys When creating overrides YAML files with nested key structures, they are being represented as flattened rather than structured keys. This leads to discrepancies in the output of the helm template command when comparing the use of --set/--set-string versus --values with an overrides YAML. While --set/--set-string correctly renders keys with their nested structure, using --values with a YAML file resulted in the omission of these nested keys. This fixes that, so nested keys work. For example, if an override was specified as ``` overrides: image.tag: "foo" ``` before this PR, the value of image.tag wouldn't be "foo", it would be the default value in the helm chart. With this PR, the value of image.tag is "foo". A new HelmSetArgumentParser class inspired by Helm's Go code for parsing --set arguments handles complex nested structures, including lists and maps, and supports type inference for values. * fix(helm): skip converting overrides to yaml if any of the overrides absolute value is >= 1,000,000 Helm 3 treats large numbers (greater than or equal to 1,000,000) as int64 when passed via --set, and as float64 when passed via --values. This behavior causes a difference in the template output, with large numeric values being output in non-scientific notation when using --set, and in scientific notation when using --values. To maintain consistent Helm 3 template behavior in Spinnaker, it is necessary to skip the overrides YAML file feature if any of the overrides' value is greater than or equal to 1,000,000. * refactor(helm test): move tests from V2BakeryControllerWithArtifactDownloaderTest to rosco-integration The tests V2BakeryControllerWithArtifactDownloaderTest depend on an executable named helm3 being in the path, and an executable named helm being helm v2. This isn't typically the case (anymore) on the local file system of developer machines. Moving the tests to rosco-integration means using the helm executables from the just-built docker image, where these dependencies are satisfied. As well, as we upgrade the versions of helm in rosco, we'll verify that override handling logic continues to function. * fix(helm): support floating point override values in values files before this, the values file would contain a string, even if rawOverrides is true. In other words, `--set my-override=1.234` would become ``` my-override: "1.234" ``` After this change, it's: ``` my-override: 1.234 ``` * fix(manifests): restore behavior that leaves float/double override values quoted The reason to leave floats quoted is that it more closely matches helm's behavior. Consider this helm chart: ``` apiVersion: v2 name: float-example description: A Helm chart example that includes a float value version: 0.1.0 appVersion: "1.0" ``` that has a values file internal to the chart (aka defaults) like: ``` threshold: 3.14 ``` and ``` apiVersion: v1 kind: ConfigMap metadata: name: float-example-config data: # Using the float directly as a numeric value numericThreshold: {{ .Values.threshold }} # Converting the float to a string stringThreshold: "{{ .Values.threshold }}" # Alternatively, using Helm's `quote` function quotedThreshold: {{ quote .Values.threshold }} thresholdTypeSprig: "{{ typeOf .Values.threshold }}" ``` With both helm 3.13.1 and 3.16.2, look at the output of various commands: ``` $ helm template float-example ./float-example --- apiVersion: v1 kind: ConfigMap metadata: name: float-example-config data: # Using the float directly as a numeric value numericThreshold: 3.14 # Converting the float to a string stringThreshold: "3.14" # Alternatively, using Helm's `quote` function quotedThreshold: "3.14" thresholdTypeSprig: "float64" ``` So far so good: there's a float value in the chart, and it appears in the output as a float. Now let's try overriding with an int value using --set: ``` $ helm template float-example ./float-example --set threshold=6 --- apiVersion: v1 kind: ConfigMap metadata: name: float-example-config data: # Using the float directly as a numeric value numericThreshold: 6 # Converting the float to a string stringThreshold: "6" # Alternatively, using Helm's `quote` function quotedThreshold: "6" thresholdTypeSprig: "int64" ``` Still OK so far. Now the clincher, let's try a decimal value using --set: ``` $ helm template float-example ./float-example --set threshold=6.28 --- apiVersion: v1 kind: ConfigMap metadata: name: float-example-config data: # Using the float directly as a numeric value numericThreshold: 6.28 # Converting the float to a string stringThreshold: "6.28" # Alternatively, using Helm's `quote` function quotedThreshold: "6.28" thresholdTypeSprig: "string" ``` The type has changed to a string! to complete the story, using --values: ``` $ cat external-values.yaml threshold: 6.28 ``` $ helm template float-example ./float-example --values external-values.yaml --- apiVersion: v1 kind: ConfigMap metadata: name: float-example-config data: # Using the float directly as a numeric value numericThreshold: 6.28 # Converting the float to a string stringThreshold: "6.28" # Alternatively, using Helm's `quote` function quotedThreshold: "6.28" thresholdTypeSprig: "float64" ``` To summarize: - default (in-chart) value of float yields a float - using --set threshold=6.28 yields a string - using --values external-values.yaml with ``` threshold: 6.28 ``` yields a float To tie this back to Spinnaker, an override in a helm bake manifest stage like: ``` threshold: 6.28 ``` ends up as a `--set` option on the helm template command line before this PR, and so it's a string in the helm chart. To preserve that behavior when the length of overrides is over the threshold, this PR has: ``` threshold: "6.28" ``` in the generated values file. Removing the quotes in the generated values file seems cleaner, but is a change in the current behavior. An alternate would be to add special logic to leave float overrides using `--set`. That's left for a future PR. --------- Co-authored-by: Arun Vijayan <[email protected]>
Co-authored-by: root <root@796c595fa7d4>
See Commits and Changes for more details.
Created by
pull[bot]
Can you help keep this open source service alive? 💖 Please sponsor : )