diff --git a/main.go b/main.go index dcd7a94..54bdba7 100644 --- a/main.go +++ b/main.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package main diff --git a/yaml/build_test.go b/yaml/build_test.go index 83c5f0c..adf387b 100644 --- a/yaml/build_test.go +++ b/yaml/build_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/compiler/clone_test.go b/yaml/compiler/clone_test.go index ef59253..cf76a33 100644 --- a/yaml/compiler/clone_test.go +++ b/yaml/compiler/clone_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/convert_test.go b/yaml/compiler/convert_test.go index 8feabac..996503c 100644 --- a/yaml/compiler/convert_test.go +++ b/yaml/compiler/convert_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/dind_test.go b/yaml/compiler/dind_test.go index afed5b1..7c2bd08 100644 --- a/yaml/compiler/dind_test.go +++ b/yaml/compiler/dind_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/encode_test.go b/yaml/compiler/encode_test.go index eeb0192..83b93c4 100644 --- a/yaml/compiler/encode_test.go +++ b/yaml/compiler/encode_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/image/image_test.go b/yaml/compiler/image/image_test.go index 61c08a5..8dc4730 100644 --- a/yaml/compiler/image/image_test.go +++ b/yaml/compiler/image/image_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package image diff --git a/yaml/compiler/script_posix_test.go b/yaml/compiler/script_posix_test.go index 5f10de1..a527b54 100644 --- a/yaml/compiler/script_posix_test.go +++ b/yaml/compiler/script_posix_test.go @@ -1,5 +1,5 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/script_win_test.go b/yaml/compiler/script_win_test.go index 5f10de1..a527b54 100644 --- a/yaml/compiler/script_win_test.go +++ b/yaml/compiler/script_win_test.go @@ -1,5 +1,5 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/skip_test.go b/yaml/compiler/skip_test.go index 683b77d..f9de2cd 100644 --- a/yaml/compiler/skip_test.go +++ b/yaml/compiler/skip_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/compiler/transform/auths_test.go b/yaml/compiler/transform/auths_test.go index aabcc7c..67f43db 100644 --- a/yaml/compiler/transform/auths_test.go +++ b/yaml/compiler/transform/auths_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/combine_test.go b/yaml/compiler/transform/combine_test.go index 4db3f76..b015078 100644 --- a/yaml/compiler/transform/combine_test.go +++ b/yaml/compiler/transform/combine_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/env_test.go b/yaml/compiler/transform/env_test.go index 28e3af0..ca8daac 100644 --- a/yaml/compiler/transform/env_test.go +++ b/yaml/compiler/transform/env_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/filter_test.go b/yaml/compiler/transform/filter_test.go index f2eb83d..177fa9d 100644 --- a/yaml/compiler/transform/filter_test.go +++ b/yaml/compiler/transform/filter_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/labels_test.go b/yaml/compiler/transform/labels_test.go index 9f622fe..3d9e718 100644 --- a/yaml/compiler/transform/labels_test.go +++ b/yaml/compiler/transform/labels_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/limits_test.go b/yaml/compiler/transform/limits_test.go index e464848..59ad324 100644 --- a/yaml/compiler/transform/limits_test.go +++ b/yaml/compiler/transform/limits_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/netrc_test.go b/yaml/compiler/transform/netrc_test.go index 04a278b..9f4588a 100644 --- a/yaml/compiler/transform/netrc_test.go +++ b/yaml/compiler/transform/netrc_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/network_test.go b/yaml/compiler/transform/network_test.go index 68c24b0..a1fa291 100644 --- a/yaml/compiler/transform/network_test.go +++ b/yaml/compiler/transform/network_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/proxy_test.go b/yaml/compiler/transform/proxy_test.go index 85b7ee5..f02f9bd 100644 --- a/yaml/compiler/transform/proxy_test.go +++ b/yaml/compiler/transform/proxy_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/secret_test.go b/yaml/compiler/transform/secret_test.go index 5066e78..4379902 100644 --- a/yaml/compiler/transform/secret_test.go +++ b/yaml/compiler/transform/secret_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/transform/volume_test.go b/yaml/compiler/transform/volume_test.go index 4dffcb8..abacb45 100644 --- a/yaml/compiler/transform/volume_test.go +++ b/yaml/compiler/transform/volume_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package transform diff --git a/yaml/compiler/workspace_test.go b/yaml/compiler/workspace_test.go index 5477215..aa216f7 100644 --- a/yaml/compiler/workspace_test.go +++ b/yaml/compiler/workspace_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package compiler diff --git a/yaml/cond_test.go b/yaml/cond_test.go index efd9885..1b12f9a 100644 --- a/yaml/cond_test.go +++ b/yaml/cond_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/bitbucket/config.go b/yaml/converter/bitbucket/config.go index 575beeb..a27c25b 100644 --- a/yaml/converter/bitbucket/config.go +++ b/yaml/converter/bitbucket/config.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package bitbucket diff --git a/yaml/converter/bitbucket/config_test.go b/yaml/converter/bitbucket/config_test.go index bb11b2f..6a93414 100644 --- a/yaml/converter/bitbucket/config_test.go +++ b/yaml/converter/bitbucket/config_test.go @@ -1,5 +1,5 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package bitbucket diff --git a/yaml/converter/bitbucket/convert.go b/yaml/converter/bitbucket/convert.go index 436b1a7..ec369ec 100644 --- a/yaml/converter/bitbucket/convert.go +++ b/yaml/converter/bitbucket/convert.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package bitbucket diff --git a/yaml/converter/bitbucket/convert_test.go b/yaml/converter/bitbucket/convert_test.go index 62455ce..05d406f 100644 --- a/yaml/converter/bitbucket/convert_test.go +++ b/yaml/converter/bitbucket/convert_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package bitbucket diff --git a/yaml/converter/convert.go b/yaml/converter/convert.go index f60e7ba..d6feff2 100644 --- a/yaml/converter/convert.go +++ b/yaml/converter/convert.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/converter/convert_test.go b/yaml/converter/convert_test.go index 587966c..51ec404 100644 --- a/yaml/converter/convert_test.go +++ b/yaml/converter/convert_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/converter/gitlab/config.go b/yaml/converter/gitlab/config.go index 0e1b6d7..bab4c04 100644 --- a/yaml/converter/gitlab/config.go +++ b/yaml/converter/gitlab/config.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package gitlab diff --git a/yaml/converter/gitlab/convert.go b/yaml/converter/gitlab/convert.go index eeb8f6c..68b8fe2 100644 --- a/yaml/converter/gitlab/convert.go +++ b/yaml/converter/gitlab/convert.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package gitlab diff --git a/yaml/converter/gitlab/convert_test.go b/yaml/converter/gitlab/convert_test.go index 32f2910..58adefa 100644 --- a/yaml/converter/gitlab/convert_test.go +++ b/yaml/converter/gitlab/convert_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package gitlab diff --git a/yaml/converter/internal/string_slice.go b/yaml/converter/internal/string_slice.go index 567b2f7..9fdbef8 100644 --- a/yaml/converter/internal/string_slice.go +++ b/yaml/converter/internal/string_slice.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package internal diff --git a/yaml/converter/internal/string_slice_test.go b/yaml/converter/internal/string_slice_test.go index 9e0e20a..c924d35 100644 --- a/yaml/converter/internal/string_slice_test.go +++ b/yaml/converter/internal/string_slice_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package internal diff --git a/yaml/converter/legacy/convert.go b/yaml/converter/legacy/convert.go index 15e5880..cb80e70 100644 --- a/yaml/converter/legacy/convert.go +++ b/yaml/converter/legacy/convert.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package legacy diff --git a/yaml/converter/legacy/internal/config.go b/yaml/converter/legacy/internal/config.go index d292feb..671cb27 100644 --- a/yaml/converter/legacy/internal/config.go +++ b/yaml/converter/legacy/internal/config.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/config_test.go b/yaml/converter/legacy/internal/config_test.go index b301743..ad0290e 100644 --- a/yaml/converter/legacy/internal/config_test.go +++ b/yaml/converter/legacy/internal/config_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/constraint.go b/yaml/converter/legacy/internal/constraint.go index eaf7ca3..8131a17 100644 --- a/yaml/converter/legacy/internal/constraint.go +++ b/yaml/converter/legacy/internal/constraint.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/container.go b/yaml/converter/legacy/internal/container.go index 68986ca..82f2cb0 100644 --- a/yaml/converter/legacy/internal/container.go +++ b/yaml/converter/legacy/internal/container.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/container_test.go b/yaml/converter/legacy/internal/container_test.go index 2f8b1cf..1e5a3eb 100644 --- a/yaml/converter/legacy/internal/container_test.go +++ b/yaml/converter/legacy/internal/container_test.go @@ -1,5 +1,5 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/secret.go b/yaml/converter/legacy/internal/secret.go index 66bae93..84e3cb1 100644 --- a/yaml/converter/legacy/internal/secret.go +++ b/yaml/converter/legacy/internal/secret.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/secret_test.go b/yaml/converter/legacy/internal/secret_test.go index 65c4129..0eb9d0d 100644 --- a/yaml/converter/legacy/internal/secret_test.go +++ b/yaml/converter/legacy/internal/secret_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/slice_map.go b/yaml/converter/legacy/internal/slice_map.go index 0d06302..0630d90 100644 --- a/yaml/converter/legacy/internal/slice_map.go +++ b/yaml/converter/legacy/internal/slice_map.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/slice_map_test.go b/yaml/converter/legacy/internal/slice_map_test.go index 0e31d81..6677b75 100644 --- a/yaml/converter/legacy/internal/slice_map_test.go +++ b/yaml/converter/legacy/internal/slice_map_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/string_slice.go b/yaml/converter/legacy/internal/string_slice.go index 243647c..39d3404 100644 --- a/yaml/converter/legacy/internal/string_slice.go +++ b/yaml/converter/legacy/internal/string_slice.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/string_slice_test.go b/yaml/converter/legacy/internal/string_slice_test.go index 9cfece6..88a33d7 100644 --- a/yaml/converter/legacy/internal/string_slice_test.go +++ b/yaml/converter/legacy/internal/string_slice_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/volume.go b/yaml/converter/legacy/internal/volume.go index 314934e..111a885 100644 --- a/yaml/converter/legacy/internal/volume.go +++ b/yaml/converter/legacy/internal/volume.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/internal/volume_test.go b/yaml/converter/legacy/internal/volume_test.go index dbbda19..55d95ed 100644 --- a/yaml/converter/legacy/internal/volume_test.go +++ b/yaml/converter/legacy/internal/volume_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/converter/legacy/match.go b/yaml/converter/legacy/match.go index d9cc49c..d851112 100644 --- a/yaml/converter/legacy/match.go +++ b/yaml/converter/legacy/match.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package legacy diff --git a/yaml/converter/legacy/match_test.go b/yaml/converter/legacy/match_test.go index 0039861..8e65bc9 100644 --- a/yaml/converter/legacy/match_test.go +++ b/yaml/converter/legacy/match_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package legacy diff --git a/yaml/converter/legacy/matrix/matrix.go b/yaml/converter/legacy/matrix/matrix.go index 9a9d5a3..786de2a 100644 --- a/yaml/converter/legacy/matrix/matrix.go +++ b/yaml/converter/legacy/matrix/matrix.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package matrix diff --git a/yaml/cron_test.go b/yaml/cron_test.go index 0451617..552f8b8 100644 --- a/yaml/cron_test.go +++ b/yaml/cron_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/env.go b/yaml/env.go index 67caa56..5dbae74 100644 --- a/yaml/env.go +++ b/yaml/env.go @@ -1,11 +1,11 @@ // Copyright 2019 Drone IO, 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/yaml/env_test.go b/yaml/env_test.go index b6251e4..5961dbc 100644 --- a/yaml/env_test.go +++ b/yaml/env_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/from_secret.go b/yaml/from_secret.go new file mode 100644 index 0000000..dc69d31 --- /dev/null +++ b/yaml/from_secret.go @@ -0,0 +1,50 @@ +// Copyright 2019 Drone IO, 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 yaml + +type ( + // FromSecret defines a secret sources from an external value. + // This could be a named secret stored in the Drone database, + // or a secret stored at an external path in a key value + // system such as Vault. + FromSecret struct { + Name string `json:"name"` + Path string `json:"path"` + } + + // fromSecret is a tempoary type used to unmarshal + // from_secret which may be short form vs long form. + fromSecret struct { + Name string `json:"name"` + Path string `json:"path"` + } +) + +// UnmarshalYAML implements yaml unmarshalling. +func (v *FromSecret) UnmarshalYAML(unmarshal func(interface{}) error) error { + err := unmarshal(&v.Name) + if err == nil { + return nil + } + + s := struct { + Name string + Path string + }{} + err = unmarshal(&s) + v.Name = s.Name + v.Path = s.Path + return err +} diff --git a/yaml/from_secret_test.go b/yaml/from_secret_test.go new file mode 100644 index 0000000..5336eac --- /dev/null +++ b/yaml/from_secret_test.go @@ -0,0 +1,50 @@ +// Copyright 2019 Drone.IO Inc. All rights reserved. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. + +package yaml + +import ( + "testing" + + "gopkg.in/yaml.v2" +) + +func TestFromSecret(t *testing.T) { + tests := []struct { + yaml string + name string + path string + }{ + { + yaml: "bar", + name: "bar", + path: "", + }, + { + yaml: "{ name: bar }", + name: "bar", + path: "", + }, + { + yaml: "{ name: bar, path: foo }", + name: "bar", + path: "foo", + }, + } + for _, test := range tests { + in := []byte(test.yaml) + out := new(FromSecret) + err := yaml.Unmarshal(in, out) + if err != nil { + t.Error(err) + return + } + if got, want := out.Name, test.name; got != want { + t.Errorf("Want from_secret name %q, got %q", want, got) + } + if got, want := out.Path, test.path; got != want { + t.Errorf("Want from_secret path %q, got %q", want, got) + } + } +} diff --git a/yaml/linter/config_test.go b/yaml/linter/config_test.go index 35973a2..e12b6f8 100644 --- a/yaml/linter/config_test.go +++ b/yaml/linter/config_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package linter diff --git a/yaml/linter/linter_test.go b/yaml/linter/linter_test.go index 4717981..e36a26e 100644 --- a/yaml/linter/linter_test.go +++ b/yaml/linter/linter_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package linter diff --git a/yaml/manifest_test.go b/yaml/manifest_test.go index 94fd553..48854bc 100644 --- a/yaml/manifest_test.go +++ b/yaml/manifest_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/param_test.go b/yaml/param_test.go index fd5a2d7..1136b13 100644 --- a/yaml/param_test.go +++ b/yaml/param_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/parse_test.go b/yaml/parse_test.go index 6ae7eb4..901b33d 100644 --- a/yaml/parse_test.go +++ b/yaml/parse_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/pipeline_test.go b/yaml/pipeline_test.go index b486e04..828ec3d 100644 --- a/yaml/pipeline_test.go +++ b/yaml/pipeline_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/port_test.go b/yaml/port_test.go index 86f9ee9..8480cee 100644 --- a/yaml/port_test.go +++ b/yaml/port_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/pretty/container.go b/yaml/pretty/container.go index c47f44e..def83cb 100644 --- a/yaml/pretty/container.go +++ b/yaml/pretty/container.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/container_test.go b/yaml/pretty/container_test.go index 631414b..431da00 100644 --- a/yaml/pretty/container_test.go +++ b/yaml/pretty/container_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/cron.go b/yaml/pretty/cron.go index bbfe9e1..4722065 100644 --- a/yaml/pretty/cron.go +++ b/yaml/pretty/cron.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/cron_test.go b/yaml/pretty/cron_test.go index 2042ea9..1de6cb9 100644 --- a/yaml/pretty/cron_test.go +++ b/yaml/pretty/cron_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/pipeline.go b/yaml/pretty/pipeline.go index 58fbe30..2787476 100644 --- a/yaml/pretty/pipeline.go +++ b/yaml/pretty/pipeline.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/pipeline_test.go b/yaml/pretty/pipeline_test.go index c53d600..a38c8cd 100644 --- a/yaml/pretty/pipeline_test.go +++ b/yaml/pretty/pipeline_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/pretty.go b/yaml/pretty/pretty.go index 10ca4bf..9997769 100644 --- a/yaml/pretty/pretty.go +++ b/yaml/pretty/pretty.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/pretty_test.go b/yaml/pretty/pretty_test.go index efdca5e..3b52f3d 100644 --- a/yaml/pretty/pretty_test.go +++ b/yaml/pretty/pretty_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/registry.go b/yaml/pretty/registry.go index df1d573..773b215 100644 --- a/yaml/pretty/registry.go +++ b/yaml/pretty/registry.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/registry_test.go b/yaml/pretty/registry_test.go index 415a8b3..5375968 100644 --- a/yaml/pretty/registry_test.go +++ b/yaml/pretty/registry_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/secret.go b/yaml/pretty/secret.go index 811be30..13cace6 100644 --- a/yaml/pretty/secret.go +++ b/yaml/pretty/secret.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/secret_test.go b/yaml/pretty/secret_test.go index af888de..2c3d78d 100644 --- a/yaml/pretty/secret_test.go +++ b/yaml/pretty/secret_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/signature.go b/yaml/pretty/signature.go index b6ca49a..ec6172c 100644 --- a/yaml/pretty/signature.go +++ b/yaml/pretty/signature.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/signature_test.go b/yaml/pretty/signature_test.go index ed42aed..2b23045 100644 --- a/yaml/pretty/signature_test.go +++ b/yaml/pretty/signature_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/util.go b/yaml/pretty/util.go index ad52949..f4902d0 100644 --- a/yaml/pretty/util.go +++ b/yaml/pretty/util.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/util_test.go b/yaml/pretty/util_test.go index 35c30aa..0f860ba 100644 --- a/yaml/pretty/util_test.go +++ b/yaml/pretty/util_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/writer.go b/yaml/pretty/writer.go index 476398f..d1d09c9 100644 --- a/yaml/pretty/writer.go +++ b/yaml/pretty/writer.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/pretty/writer_test.go b/yaml/pretty/writer_test.go index d4dc85b..c07ce0a 100644 --- a/yaml/pretty/writer_test.go +++ b/yaml/pretty/writer_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. // +build !oss diff --git a/yaml/push_test.go b/yaml/push_test.go index 7ed0d02..f447142 100644 --- a/yaml/push_test.go +++ b/yaml/push_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/registry_test.go b/yaml/registry_test.go index ad12ce9..da6ac25 100644 --- a/yaml/registry_test.go +++ b/yaml/registry_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/secret.go b/yaml/secret.go index dd0b212..2b742ab 100644 --- a/yaml/secret.go +++ b/yaml/secret.go @@ -1,11 +1,11 @@ // Copyright 2019 Drone IO, 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. @@ -16,6 +16,9 @@ package yaml import "errors" +// TODO(bradrydzewski) deprecate Secret +// TODO(bradrydzewski) deprecate ExternalData + type ( // Secret is a resource that provides encrypted data // and pointers to external data (i.e. from vault). diff --git a/yaml/secret_test.go b/yaml/secret_test.go index 3daa129..d9d3b4a 100644 --- a/yaml/secret_test.go +++ b/yaml/secret_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/signature_test.go b/yaml/signature_test.go index 878ccdc..352c10a 100644 --- a/yaml/signature_test.go +++ b/yaml/signature_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml diff --git a/yaml/unit_test.go b/yaml/unit_test.go index 94200a2..fd67cff 100644 --- a/yaml/unit_test.go +++ b/yaml/unit_test.go @@ -1,6 +1,6 @@ // Copyright 2019 Drone.IO Inc. All rights reserved. -// Use of this source code is governed by the Drone Community -// License that can be found in the LICENSE file. +// Use of this source code is governed by the Drone Non-Commercial License +// that can be found in the LICENSE file. package yaml