diff --git a/.github/workflows/security.yaml b/.github/workflows/security.yaml index 23d9b49e54..cc4ccc964d 100644 --- a/.github/workflows/security.yaml +++ b/.github/workflows/security.yaml @@ -51,7 +51,7 @@ jobs: with: go-version-file: 'go.mod' check-latest: true - - name: lint + - name: vuln shell: bash run: | make vuln diff --git a/.github/workflows/validate.yml b/.github/workflows/validate.yml index 6a9a371e3e..8384947035 100644 --- a/.github/workflows/validate.yml +++ b/.github/workflows/validate.yml @@ -22,18 +22,24 @@ on: branches: - main - "release-*" - paths: - - 'pkg/**' - - 'cmd/**' - - 'addons/**' + paths-ignore: + - 'proposals/**' + - '**.adoc' + - '**.md' + - 'KEYS' + - 'LICENSE' + - 'NOTICE' push: branches: - main - "release-*" - paths: - - 'pkg/**' - - 'cmd/**' - - 'addons/**' + paths-ignore: + - 'proposals/**' + - '**.md' + - '**.adoc' + - 'KEYS' + - 'LICENSE' + - 'NOTICE' concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} @@ -54,3 +60,7 @@ jobs: shell: bash run: | make lint + - name: licenses + shell: bash + run: | + make check-licenses \ No newline at end of file diff --git a/e2e/advanced/files/camel-k-tekton.yaml b/e2e/advanced/files/camel-k-tekton.yaml index 6cee0a139a..16c663b30f 100644 --- a/e2e/advanced/files/camel-k-tekton.yaml +++ b/e2e/advanced/files/camel-k-tekton.yaml @@ -1,3 +1,20 @@ +# --------------------------------------------------------------------------- +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You 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. +# --------------------------------------------------------------------------- + --- apiVersion: v1 kind: ServiceAccount diff --git a/e2e/advanced/files/promote-route-edited.yaml b/e2e/advanced/files/promote-route-edited.yaml index 448240a69e..6556fc0328 100644 --- a/e2e/advanced/files/promote-route-edited.yaml +++ b/e2e/advanced/files/promote-route-edited.yaml @@ -1,5 +1,6 @@ # camel-k: language=yaml +# --------------------------------------------------------------------------- # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. @@ -14,6 +15,7 @@ # 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. +# --------------------------------------------------------------------------- - from: uri: "timer:configmap" diff --git a/e2e/advanced/files/promote-route.yaml b/e2e/advanced/files/promote-route.yaml index cb915b6efa..290a2ac02f 100644 --- a/e2e/advanced/files/promote-route.yaml +++ b/e2e/advanced/files/promote-route.yaml @@ -1,5 +1,6 @@ # camel-k: language=yaml +# --------------------------------------------------------------------------- # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. @@ -14,6 +15,7 @@ # 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. +# --------------------------------------------------------------------------- - from: uri: "timer:configmap" diff --git a/e2e/advanced/files/timer-kamelet-usage.yaml b/e2e/advanced/files/timer-kamelet-usage.yaml index c04b36b556..206ba027b0 100644 --- a/e2e/advanced/files/timer-kamelet-usage.yaml +++ b/e2e/advanced/files/timer-kamelet-usage.yaml @@ -1,3 +1,4 @@ +# --------------------------------------------------------------------------- # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. @@ -12,6 +13,7 @@ # 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. +# --------------------------------------------------------------------------- - from: uri: "kamelet:my-own-timer-source?message=Hello+world" diff --git a/e2e/advanced/files/timer-source.yaml b/e2e/advanced/files/timer-source.yaml index e80528db13..36a97142cb 100644 --- a/e2e/advanced/files/timer-source.yaml +++ b/e2e/advanced/files/timer-source.yaml @@ -1,5 +1,6 @@ # camel-k: language=yaml +# --------------------------------------------------------------------------- # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. @@ -14,6 +15,7 @@ # 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. +# --------------------------------------------------------------------------- - from: uri: "kamelet:timer-source?message=Magicstring!&period=3000" diff --git a/e2e/common/traits/files/PodTest.yaml b/e2e/common/traits/files/PodTest.yaml index 08f71974b0..a8b6bcb80b 100644 --- a/e2e/common/traits/files/PodTest.yaml +++ b/e2e/common/traits/files/PodTest.yaml @@ -1,5 +1,6 @@ # camel-k: language=yaml +# --------------------------------------------------------------------------- # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. @@ -14,6 +15,7 @@ # 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. +# --------------------------------------------------------------------------- - from: uri: "file:///var/log" diff --git a/script/check_licenses.sh b/script/check_licenses.sh index c66e63da8c..e9c31f04a2 100755 --- a/script/check_licenses.sh +++ b/script/check_licenses.sh @@ -29,7 +29,7 @@ check_licenses() { set +e failed=0 - find . -type f -name "$files" -print0 | while IFS= read -r -d '' file; do + while IFS= read -r -d '' file; do check=true for b in ${denylist[*]}; do if [[ "$file" == *"$b"* ]]; then @@ -44,7 +44,7 @@ check_licenses() { failed=1 fi fi - done + done < <(find . -type f -name "$files" -print0) set -e if [ $failed -ne 0 ]; then