diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5ded3ed28..ebc9305ea 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,6 +18,9 @@ jobs: - name: Checkout code into the Go module directory uses: actions/checkout@v2 + - name: Validate license headers + run: make validate + - name: Run golangci-lint run: | curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b . v1.30.0 diff --git a/Dockerfile b/Dockerfile index 4c8d90a39..4bd56202b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,6 @@ -# syntax = docker/dockerfile:experimental +# syntax=docker/dockerfile:experimental + + # Copyright 2020 Docker, Inc. # Licensed under the Apache License, Version 2.0 (the "License"); @@ -84,3 +86,10 @@ RUN --mount=target=. \ BUILD_TAGS=${BUILD_TAGS} \ GIT_TAG=${GIT_TAG} \ make -f builder.Makefile test + +FROM base as check-license-headers +RUN go get -u github.com/kunalkushwaha/ltag +RUN --mount=target=. \ + --mount=type=cache,target=/root/.cache/go-build \ + make -f builder.Makefile check-license-headers + diff --git a/Makefile b/Makefile index 720c38a84..b04403abf 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -# Copyright 2020 The 2020 Docker, Inc. +# Copyright 2020 Docker, Inc. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -78,6 +78,9 @@ serve: cli ## start server moby-cli-link: ## create com.docker.cli symlink if does not already exist ln -s $(MOBY_DOCKER) /usr/local/bin/com.docker.cli +validate: ## check license header for all files + @docker build . --target check-license-headers + help: ## Show help @echo Please specify a build target. The choices are: @grep -E '^[0-9a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' diff --git a/aci/aci_test.go b/aci/aci_test.go index 145bf2802..22efe8eab 100644 --- a/aci/aci_test.go +++ b/aci/aci_test.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package aci import ( diff --git a/aci/convert/container.go b/aci/convert/container.go index 6929e97fd..742e7f7e1 100644 --- a/aci/convert/container.go +++ b/aci/convert/container.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package convert import ( diff --git a/aci/login/client.go b/aci/login/client.go index ad92441bb..6175fd2fd 100644 --- a/aci/login/client.go +++ b/aci/login/client.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package login import ( diff --git a/aci/login/storage_helper.go b/aci/login/storage_helper.go index 51d047462..2cc5d59b2 100644 --- a/aci/login/storage_helper.go +++ b/aci/login/storage_helper.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package login import ( diff --git a/builder.Makefile b/builder.Makefile index b5e131484..7b5069114 100644 --- a/builder.Makefile +++ b/builder.Makefile @@ -56,6 +56,9 @@ test: lint: golangci-lint run --timeout 10m0s ./... +check-license-headers: + ./scripts/validate/fileheader + FORCE: .PHONY: all protos cli cross test lint diff --git a/cli/cmd/login/azurelogin.go b/cli/cmd/login/azurelogin.go index 4b7f3a28f..433ad5501 100644 --- a/cli/cmd/login/azurelogin.go +++ b/cli/cmd/login/azurelogin.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package login import ( diff --git a/cli/cmd/logout/azure.go b/cli/cmd/logout/azure.go index 478f821cf..a976b800b 100644 --- a/cli/cmd/logout/azure.go +++ b/cli/cmd/logout/azure.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package logout import ( diff --git a/cli/cmd/logout/logout.go b/cli/cmd/logout/logout.go index cfc63ed3e..bea8a8e53 100644 --- a/cli/cmd/logout/logout.go +++ b/cli/cmd/logout/logout.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package logout import ( diff --git a/cli/cmd/mobyflags/mobyflags.go b/cli/cmd/mobyflags/mobyflags.go index dcce02d8b..e6c7bcf1a 100644 --- a/cli/cmd/mobyflags/mobyflags.go +++ b/cli/cmd/mobyflags/mobyflags.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package mobyflags import ( diff --git a/cli/mobycli/delegate_ecs.go b/cli/mobycli/delegate_ecs.go index dccc7e095..65415e8c0 100644 --- a/cli/mobycli/delegate_ecs.go +++ b/cli/mobycli/delegate_ecs.go @@ -1,5 +1,21 @@ // +build !ecs +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package mobycli import "github.com/docker/api/context/store" diff --git a/cli/mobycli/exec_test.go b/cli/mobycli/exec_test.go index ed186b892..8c1f18c20 100644 --- a/cli/mobycli/exec_test.go +++ b/cli/mobycli/exec_test.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package mobycli import ( diff --git a/docs/install/install.sh b/docs/install/install.sh index 62fd74279..aa6800372 100755 --- a/docs/install/install.sh +++ b/docs/install/install.sh @@ -1,5 +1,20 @@ #!/bin/sh +# Copyright 2020 Docker, Inc. + +# 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. + + # Script to install the Docker ACI integration CLI on Ubuntu (Beta). set -eu diff --git a/ecs/backend.go b/ecs/backend.go index 4997ecb9c..156289e79 100644 --- a/ecs/backend.go +++ b/ecs/backend.go @@ -1,9 +1,12 @@ /* Copyright 2020 Docker, Inc. + 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. diff --git a/ecs/context.go b/ecs/context.go index 46c2422ec..e40202cb7 100644 --- a/ecs/context.go +++ b/ecs/context.go @@ -1,9 +1,12 @@ /* Copyright 2020 Docker, Inc. + 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. diff --git a/ecs/doc.go b/ecs/doc.go new file mode 100644 index 000000000..74f8b51d2 --- /dev/null +++ b/ecs/doc.go @@ -0,0 +1,17 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + +package ecs diff --git a/go.mod b/go.mod index 172569e25..0f3a4472d 100644 --- a/go.mod +++ b/go.mod @@ -19,7 +19,7 @@ require ( github.com/Azure/go-autorest/autorest/validation v0.2.0 // indirect github.com/Microsoft/go-winio v0.4.15-0.20190919025122-fc70bd9a86b5 github.com/Microsoft/hcsshim v0.8.9 // indirect - github.com/aws/aws-sdk-go v1.34.2 + github.com/aws/aws-sdk-go v1.34.6 github.com/awslabs/goformation/v4 v4.14.0 github.com/buger/goterm v0.0.0-20200322175922-2f3e71b85129 github.com/compose-spec/compose-go v0.0.0-20200818070525-eb1188aae4a2 @@ -58,6 +58,6 @@ require ( google.golang.org/grpc v1.31.0 google.golang.org/protobuf v1.25.0 gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect - gopkg.in/ini.v1 v1.58.0 + gopkg.in/ini.v1 v1.60.0 gotest.tools/v3 v3.0.2 ) diff --git a/go.sum b/go.sum index 32d81a88c..2afc5e41f 100644 --- a/go.sum +++ b/go.sum @@ -66,6 +66,8 @@ github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5 github.com/aws/aws-sdk-go v1.15.11/go.mod h1:mFuSZ37Z9YOHbQEwBWztmVzqXrEkub65tZoCYDt7FT0= github.com/aws/aws-sdk-go v1.34.2 h1:9vCknCdTAmmV4ht7lPuda7aJXzllXwEQyCMZKJHjBrM= github.com/aws/aws-sdk-go v1.34.2/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= +github.com/aws/aws-sdk-go v1.34.6 h1:2aPXQGkR6xeheN5dns13mSoDWeUlj4wDmfZ+8ZDHauw= +github.com/aws/aws-sdk-go v1.34.6/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/awslabs/goformation/v4 v4.14.0 h1:E2Pet9eIqA4qzt3dzzzE4YN83V4Kyfbcio0VokBC9TA= github.com/awslabs/goformation/v4 v4.14.0/go.mod h1:GcJULxCJfloT+3pbqCluXftdEK2AD/UqpS3hkaaBntg= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= @@ -534,6 +536,8 @@ gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/ini.v1 v1.58.0 h1:VdDvTzv/005R8vEFyQ56bpEnOKTNPbpJhL0VCohxlQw= gopkg.in/ini.v1 v1.58.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= +gopkg.in/ini.v1 v1.60.0 h1:P5ZzC7RJO04094NJYlEnBdFK2wwmnCAy/+7sAzvWs60= +gopkg.in/ini.v1 v1.60.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= diff --git a/prompt/prompt.go b/prompt/prompt.go index 34623b933..d23904cc2 100644 --- a/prompt/prompt.go +++ b/prompt/prompt.go @@ -1,9 +1,12 @@ /* Copyright 2020 Docker, Inc. + 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. diff --git a/scripts/validate/fileheader b/scripts/validate/fileheader new file mode 100755 index 000000000..5f07a6cd2 --- /dev/null +++ b/scripts/validate/fileheader @@ -0,0 +1,28 @@ +#!/usr/bin/env sh + +# Copyright The Compose Specification 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. + + +set -eu -o pipefail + +if ! command -v ltag; then + >&2 echo "ERROR: ltag not found. Install with:" + >&2 echo " go get -u github.com/kunalkushwaha/ltag" + exit 1 +fi + +BASEPATH="${1-}" + +ltag -t "${BASEPATH}scripts/validate/template" -excludes "validate testdata" --check -v \ No newline at end of file diff --git a/scripts/validate/template/bash.txt b/scripts/validate/template/bash.txt new file mode 100644 index 000000000..6d89e6173 --- /dev/null +++ b/scripts/validate/template/bash.txt @@ -0,0 +1,13 @@ +# Copyright 2020 Docker, Inc. + +# 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. diff --git a/scripts/validate/template/dockerfile.txt b/scripts/validate/template/dockerfile.txt new file mode 100644 index 000000000..6d89e6173 --- /dev/null +++ b/scripts/validate/template/dockerfile.txt @@ -0,0 +1,13 @@ +# Copyright 2020 Docker, Inc. + +# 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. diff --git a/scripts/validate/template/go.txt b/scripts/validate/template/go.txt new file mode 100644 index 000000000..1cd855449 --- /dev/null +++ b/scripts/validate/template/go.txt @@ -0,0 +1,16 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + diff --git a/scripts/validate/template/makefile.txt b/scripts/validate/template/makefile.txt new file mode 100644 index 000000000..6d89e6173 --- /dev/null +++ b/scripts/validate/template/makefile.txt @@ -0,0 +1,13 @@ +# Copyright 2020 Docker, Inc. + +# 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. diff --git a/server/proxy/containers_test.go b/server/proxy/containers_test.go index 2c0aee2b9..93fe228a2 100644 --- a/server/proxy/containers_test.go +++ b/server/proxy/containers_test.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package proxy import ( diff --git a/tests/composefiles/aci-demo/db/Dockerfile b/tests/composefiles/aci-demo/db/Dockerfile index 35f0e8550..693541387 100644 --- a/tests/composefiles/aci-demo/db/Dockerfile +++ b/tests/composefiles/aci-demo/db/Dockerfile @@ -1,3 +1,16 @@ +# Copyright 2020 Docker, Inc. + +# 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. FROM postgres:10.0-alpine COPY words.sql /docker-entrypoint-initdb.d/ diff --git a/tests/composefiles/aci-demo/web/Dockerfile b/tests/composefiles/aci-demo/web/Dockerfile index 2dd000aef..47ed36860 100644 --- a/tests/composefiles/aci-demo/web/Dockerfile +++ b/tests/composefiles/aci-demo/web/Dockerfile @@ -1,3 +1,16 @@ +# Copyright 2020 Docker, Inc. + +# 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. # BUILD FROM ubuntu:latest diff --git a/tests/composefiles/aci-demo/words/Dockerfile b/tests/composefiles/aci-demo/words/Dockerfile index 6171e2361..f2c7652c5 100644 --- a/tests/composefiles/aci-demo/words/Dockerfile +++ b/tests/composefiles/aci-demo/words/Dockerfile @@ -1,3 +1,16 @@ +# Copyright 2020 Docker, Inc. + +# 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. # BUILD FROM openjdk:8u171-jdk-alpine as build diff --git a/utils/stringutils.go b/utils/stringutils.go index 6febf8e9a..d02a3a874 100644 --- a/utils/stringutils.go +++ b/utils/stringutils.go @@ -1,3 +1,19 @@ +/* + Copyright 2020 Docker, Inc. + + 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. +*/ + package utils // StringContains check if an array contains a specific value