From 85edd13ce14b20a0c3bce274d542e9bf3675ce94 Mon Sep 17 00:00:00 2001 From: Ming Wang Date: Fri, 8 Mar 2024 10:23:06 -0500 Subject: [PATCH] add kubectl license --- go-license.yml | 20 ++++++++++++++++++++ internal/test/scorecard/common_utils.go | 2 ++ 2 files changed, 22 insertions(+) diff --git a/go-license.yml b/go-license.yml index 2a9d2d95a..f5d6506c9 100644 --- a/go-license.yml +++ b/go-license.yml @@ -13,6 +13,26 @@ header: | // See the License for the specific language governing permissions and // limitations under the License. +custom-headers: + - name: kubectl + header: | + // Copyright The Cryostat Authors. + // Copyright 2016 The Kubernetes Authors. + // + // Licensed under the Apache License, Version 2.0 (the "License"); + // you may not use this file except in compliance with the License. + // You may obtain a copy of the License at + // + // http://www.apache.org/licenses/LICENSE-2.0 + // + // Unless required by applicable law or agreed to in writing, software + // distributed under the License is distributed on an "AS IS" BASIS, + // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + // See the License for the specific language governing permissions and + // limitations under the License. + paths: + - internal/test/scorecard/common_utils.go + exclude: names: - '.*generated.*' diff --git a/internal/test/scorecard/common_utils.go b/internal/test/scorecard/common_utils.go index 96008c46a..c36dc720a 100644 --- a/internal/test/scorecard/common_utils.go +++ b/internal/test/scorecard/common_utils.go @@ -1,4 +1,5 @@ // Copyright The Cryostat Authors. +// Copyright 2016 The Kubernetes Authors. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -417,6 +418,7 @@ func updateAndWaitTillCryostatAvailable(cr *operatorv1beta1.Cryostat, resources } } + // Derived from kubectl: https://github.com/kubernetes/kubectl/blob/24d21a0/pkg/polymorphichelpers/rollout_status.go#L75-L91 // Check for deployment condition if deploy.Generation <= deploy.Status.ObservedGeneration { for _, condition := range deploy.Status.Conditions {