diff --git a/ATTRIBUTION.md b/ATTRIBUTION.md index db4d9a7..9157757 100644 --- a/ATTRIBUTION.md +++ b/ATTRIBUTION.md @@ -1,16 +1,17 @@ # Open Source Software Attribution -The AWS Controllers for Kubernetes (ACK) source code is licensed under the -Apache License, version 2.0. A copy of this license is available in the +[//]: # (File generated by attribution-gen. DO NOT EDIT.) + +The github.com/aws-controllers-k8s/s3-controller source code is licensed under the +Apache-2.0 license. A copy of this license is available in the [LICENSE](LICENSE) file in the root source code directory and is included, -along with this document, in any images containing AWS service controller +along with this document, in any images containing github.com/aws-controllers-k8s/s3-controller binaries. ## Package dependencies -ACK depends on a number of Open Source Go packages. Direct dependencies are -listed in the -[`go.mod`](https://github.com/aws/aws-controllers-k8s/tree/main/go.mod) file. +The module github.com/aws-controllers-k8s/s3-controller depends on a number of Open Source Go packages. Direct +dependencies are listed in the ./go.mod file. Those direct package dependencies have some dependencies of their own (known as "transitive dependencies") @@ -19,135 +20,162 @@ include an indication of the Open Source License under which that package is distributed. For any package *NOT* distributed under the terms of the Apache License version 2.0, we include the full text of the package's License below. +* `github.com/aws-controllers-k8s/runtime` * `github.com/aws/aws-sdk-go` -* `github.com/dlclark/regexp2` -* `github.com/gertd/go-pluralize` -* `github.com/ghodss/yaml` +* `github.com/aws/aws-sdk-go-v2` +* `github.com/aws/aws-sdk-go-v2/service/s3` +* `github.com/aws/aws-sdk-go-v2/service/s3control` +* `github.com/aws/smithy-go` * `github.com/go-logr/logr` -* `github.com/google/go-cmp` -* `github.com/iancoleman/strcase` -* `github.com/mitchellh/go-homedir` * `github.com/pkg/errors` -* `github.com/spf13/cobra` * `github.com/spf13/pflag` * `github.com/stretchr/testify` -* `golang.org/x/mod` * `k8s.io/api` * `k8s.io/apimachinery` * `k8s.io/client-go` * `sigs.k8s.io/controller-runtime` -* `sigs.k8s.io/controller-tools` - -### github.com/aws/aws-sdk-go - -Apache License version 2.0 - -### github.com/dlclark/regexp2 - -The MIT License (MIT) - -Copyright (c) Doug Clark - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. - -#### github.com/dlclark/regexp2 Attribution - -============ -These pieces of code were ported from dotnet/corefx: +### github.com/aws-controllers-k8s/runtime -syntax/charclass.go (from RegexCharClass.cs): ported to use the built-in Go unicode classes. Canonicalize is - a direct port, but most of the other code required large changes because the C# implementation - used a string to represent the CharSet data structure and I cleaned that up in my implementation. +License Identifier: Apache-2.0 -syntax/code.go (from RegexCode.cs): ported literally with various cleanups and layout to make it more Go-ish. - -syntax/escape.go (from RegexParser.cs): ported Escape method and added some optimizations. Unescape is inspired by - the C# implementation but couldn't be directly ported because of the lack of do-while syntax in Go. +Subdependencies: +* `github.com/aws/aws-sdk-go-v2` +* `github.com/aws/aws-sdk-go-v2/config` +* `github.com/aws/aws-sdk-go-v2/credentials` +* `github.com/aws/aws-sdk-go-v2/service/sts` +* `github.com/aws/smithy-go` +* `github.com/cenkalti/backoff/v4` +* `github.com/go-logr/logr` +* `github.com/google/go-cmp` +* `github.com/itchyny/gojq` +* `github.com/jaypipes/envutil` +* `github.com/pkg/errors` +* `github.com/prometheus/client_golang` +* `github.com/samber/lo` +* `github.com/spf13/pflag` +* `github.com/stretchr/testify` +* `go.uber.org/zap` +* `k8s.io/api` +* `k8s.io/apimachinery` +* `k8s.io/client-go` +* `k8s.io/klog/v2` +* `sigs.k8s.io/controller-runtime` +* `github.com/aws/aws-sdk-go-v2/feature/ec2/imds` +* `github.com/aws/aws-sdk-go-v2/internal/configsources` +* `github.com/aws/aws-sdk-go-v2/internal/endpoints/v2` +* `github.com/aws/aws-sdk-go-v2/internal/ini` +* `github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding` +* `github.com/aws/aws-sdk-go-v2/service/internal/presigned-url` +* `github.com/aws/aws-sdk-go-v2/service/sso` +* `github.com/aws/aws-sdk-go-v2/service/ssooidc` +* `github.com/beorn7/perks` +* `github.com/cespare/xxhash/v2` +* `github.com/davecgh/go-spew` +* `github.com/emicklei/go-restful/v3` +* `github.com/evanphx/json-patch` +* `github.com/evanphx/json-patch/v5` +* `github.com/fsnotify/fsnotify` +* `github.com/fxamacker/cbor/v2` +* `github.com/go-logr/zapr` +* `github.com/go-openapi/jsonpointer` +* `github.com/go-openapi/jsonreference` +* `github.com/go-openapi/swag` +* `github.com/gogo/protobuf` +* `github.com/golang/protobuf` +* `github.com/google/btree` +* `github.com/google/gnostic-models` +* `github.com/google/gofuzz` +* `github.com/google/uuid` +* `github.com/itchyny/timefmt-go` +* `github.com/josharian/intern` +* `github.com/json-iterator/go` +* `github.com/mailru/easyjson` +* `github.com/modern-go/concurrent` +* `github.com/modern-go/reflect2` +* `github.com/munnerz/goautoneg` +* `github.com/pmezard/go-difflib` +* `github.com/prometheus/client_model` +* `github.com/prometheus/common` +* `github.com/prometheus/procfs` +* `github.com/stretchr/objx` +* `github.com/x448/float16` +* `go.uber.org/multierr` +* `golang.org/x/exp` +* `golang.org/x/net` +* `golang.org/x/oauth2` +* `golang.org/x/sync` +* `golang.org/x/sys` +* `golang.org/x/term` +* `golang.org/x/text` +* `golang.org/x/time` +* `golang.org/x/tools` +* `gomodules.xyz/jsonpatch/v2` +* `google.golang.org/protobuf` +* `gopkg.in/evanphx/json-patch.v4` +* `gopkg.in/inf.v0` +* `gopkg.in/yaml.v3` +* `k8s.io/apiextensions-apiserver` +* `k8s.io/kube-openapi` +* `k8s.io/utils` +* `sigs.k8s.io/json` +* `sigs.k8s.io/structured-merge-diff/v4` +* `sigs.k8s.io/yaml` -syntax/parser.go (from RegexpParser.cs and RegexOptions.cs): ported parser struct and associated methods as - literally as possible. Several language differences required changes. E.g. lack pre/post-fix increments as - expressions, lack of do-while loops, lack of overloads, etc. +#### github.com/aws/aws-sdk-go-v2 -syntax/prefix.go (from RegexFCD.cs and RegexBoyerMoore.cs): ported as literally as possible and added support - for unicode chars that are longer than the 16-bit char in C# for the 32-bit rune in Go. +License Identifier: Apache-2.0 -syntax/replacerdata.go (from RegexReplacement.cs): conceptually ported and re-organized to handle differences - in charclass implementation, and fix odd code layout between RegexParser.cs, Regex.cs, and RegexReplacement.cs. +#### github.com/aws/aws-sdk-go-v2/config -syntax/tree.go (from RegexTree.cs and RegexNode.cs): ported literally as possible. +License Identifier: Apache-2.0 -syntax/writer.go (from RegexWriter.cs): ported literally with minor changes to make it more Go-ish. +#### github.com/aws/aws-sdk-go-v2/credentials -match.go (from RegexMatch.cs): ported, simplified, and changed to handle Go's lack of inheritence. +License Identifier: Apache-2.0 -regexp.go (from Regex.cs and RegexOptions.cs): conceptually serves the same "starting point", but is simplified - and changed to handle differences in C# strings and Go strings/runes. +#### github.com/aws/aws-sdk-go-v2/service/sts -replace.go (from RegexReplacement.cs): ported closely and then cleaned up to combine the MatchEvaluator and - simple string replace implementations. +License Identifier: Apache-2.0 -runner.go (from RegexRunner.cs): ported literally as possible. +#### github.com/aws/smithy-go -regexp_test.go (from CaptureTests.cs and GroupNamesAndNumbers.cs): conceptually ported, but the code was - manually structured like Go tests. +License Identifier: Apache-2.0 -replace_test.go (from RegexReplaceStringTest0.cs): conceptually ported +#### github.com/cenkalti/backoff/v4 -rtl_test.go (from RightToLeft.cs): conceptually ported ---- -dotnet/corefx was released under this license: +License Identifier: MIT The MIT License (MIT) -Copyright (c) Microsoft Corporation +Copyright (c) 2014 Cenk Altı -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -============ -These pieces of code are copied from the Go framework: +#### github.com/go-logr/logr -- The overall directory structure of regexp2 was inspired by the Go runtime regexp package. -- The optimization in the escape method of syntax/escape.go is from the Go runtime QuoteMeta() func in regexp/regexp.go -- The method signatures in regexp.go are designed to match the Go framework regexp methods closely -- func regexp2.MustCompile and func quote are almost identifical to the regexp package versions -- BenchmarkMatch* and TestProgramTooLong* funcs in regexp_performance_test.go were copied from the framework - regexp/exec_test.go ---- -The Go framework was released under this license: +License Identifier: Apache-2.0 -Copyright (c) 2012 The Go Authors. All rights reserved. +#### github.com/google/go-cmp + +License Identifier: BSD-3-Clause + +Copyright (c) 2017 The Go Authors. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -175,39 +203,13 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -============ -Some test data were gathered from the Mono project. - -regexp_mono_test.go: ported from https://github.com/mono/mono/blob/master/mcs/class/System/Test/System.Text.RegularExpressions/PerlTrials.cs ---- -Mono tests released under this license: - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +#### github.com/itchyny/gojq -### github.com/gertd/go-pluralize - -MIT License +License Identifier: MIT -Copyright (c) 2019 Gert Drapers +The MIT License (MIT) -Copyright (c) 2013 Blake Embrey (hello@blakeembrey.com) +Copyright (c) 2019-2021 itchyny Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -227,11 +229,49 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -### github.com/ghodss/yaml +#### github.com/jaypipes/envutil -The MIT License (MIT) +License Identifier: Apache-2.0 + +#### github.com/pkg/errors + +License Identifier: BSD-2-Clause -Copyright (c) 2014 Sam Ghods +Copyright (c) 2015, Dave Cheney +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/prometheus/client_golang + +License Identifier: Apache-2.0 + +#### github.com/samber/lo + +License Identifier: MIT + +MIT License + +Copyright (c) 2022 Samuel Berthe Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -251,7 +291,11 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +#### github.com/spf13/pflag + +License Identifier: BSD-3-Clause +Copyright (c) 2012 Alex Ogier. All rights reserved. Copyright (c) 2012 The Go Authors. All rights reserved. Redistribution and use in source and binary forms, with or without @@ -280,56 +324,23 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -### github.com/go-logr/logr +#### github.com/stretchr/testify -Apache License version 2.0 +License Identifier: MIT -### github.com/google/go-cmp - -Copyright (c) 2017 The Go Authors. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above -copyright notice, this list of conditions and the following disclaimer -in the documentation and/or other materials provided with the -distribution. - * Neither the name of Google Inc. nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -### github.com/iancoleman/strcase - -The MIT License (MIT) +MIT License -Copyright (c) 2015 Ian Coleman -Copyright (c) 2018 Ma_124, +Copyright (c) 2012-2020 Mat Ryer, Tyler Bunnell and contributors. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is -furnished to do so, Subject to the following conditions: +furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all -copies or Substantial portions of the Software. +copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, @@ -339,11 +350,9 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -### github.com/mitchellh/go-homedir - -The MIT License (MIT) +#### go.uber.org/zap -Copyright (c) 2013 Mitchell Hashimoto +Copyright (c) 2016-2017 Uber Technologies, Inc. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal @@ -363,119 +372,112 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -### github.com/pkg/errors - -Copyright (c) 2015, Dave Cheney -All rights reserved. +#### k8s.io/api -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: +License Identifier: Apache-2.0 -* Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. +#### k8s.io/apimachinery -* Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. +License Identifier: Apache-2.0 -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#### k8s.io/client-go -### github.com/spf13/cobra +License Identifier: Apache-2.0 -Apache License version 2.0 +#### k8s.io/klog/v2 -Subdependencies: +License Identifier: Apache-2.0 -* `github.com/cpuguy83/go-md2man/v2` -* `github.com/inconshreveable/mousetrap` -* `github.com/spf13/pflag` -* `gopkg.in/yaml.v2` +#### sigs.k8s.io/controller-runtime -#### github.com/cpuguy83/go-md2man +License Identifier: Apache-2.0 -The MIT License (MIT) +#### github.com/aws/aws-sdk-go-v2/feature/ec2/imds -Copyright (c) 2014 Brian Goff +License Identifier: Apache-2.0 -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: +#### github.com/aws/aws-sdk-go-v2/internal/configsources -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +License Identifier: Apache-2.0 -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +#### github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 -#### github.com/inconshreveable/mousetrap +License Identifier: Apache-2.0 -Apache License version 2.0 +#### github.com/aws/aws-sdk-go-v2/internal/ini -#### goplg.in/yaml.v2 +License Identifier: Apache-2.0 -Apache License version 2.0 +#### github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding -Subdependencies: +License Identifier: Apache-2.0 -* `gopkg.in/check.v1` +#### github.com/aws/aws-sdk-go-v2/service/internal/presigned-url -#### gopkg.in/check.v1 +License Identifier: Apache-2.0 -Apache License version 2.0 +#### github.com/aws/aws-sdk-go-v2/service/sso -### github.com/spf13/pflag` +License Identifier: Apache-2.0 -Apache License version 2.0 +#### github.com/aws/aws-sdk-go-v2/service/ssooidc -### github.com/stretchr/testify +License Identifier: Apache-2.0 -MIT License +#### github.com/beorn7/perks -Copyright (c) 2012-2020 Mat Ryer, Tyler Bunnell and contributors. +Copyright (C) 2013 Blake Mizerany -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -Subdependencies: -* `github.com/davecgh/go-spew` -* `github.com/pmezard/go-difflib` -* `github.com/stretchr/objx` -* `gopkg.in/yaml.v3` +#### github.com/cespare/xxhash/v2 + +License Identifier: MIT + +Copyright (c) 2016 Caleb Spare + +MIT License + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #### github.com/davecgh/go-spew +License Identifier: ISC + ISC License Copyright (c) 2012-2016 Dave Collins @@ -492,8 +494,416 @@ WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +#### github.com/emicklei/go-restful/v3 + +License Identifier: MIT + +Copyright (c) 2012,2013 Ernest Micklei + +MIT License + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +#### github.com/evanphx/json-patch + +License Identifier: BSD-3-Clause + +Copyright (c) 2014, Evan Phoenix +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +* Neither the name of the Evan Phoenix nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/evanphx/json-patch/v5 + +License Identifier: BSD-3-Clause + +Copyright (c) 2014, Evan Phoenix +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +* Neither the name of the Evan Phoenix nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/fsnotify/fsnotify + +License Identifier: BSD-3-Clause + +Copyright © 2012 The Go Authors. All rights reserved. +Copyright © fsnotify Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright notice, this + list of conditions and the following disclaimer in the documentation and/or + other materials provided with the distribution. +* Neither the name of Google Inc. nor the names of its contributors may be used + to endorse or promote products derived from this software without specific + prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/fxamacker/cbor/v2 + +License Identifier: MIT + +MIT License + +Copyright (c) 2019-present Faye Amacker + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +#### github.com/go-logr/zapr + +License Identifier: Apache-2.0 + +#### github.com/go-openapi/jsonpointer + +License Identifier: Apache-2.0 + +#### github.com/go-openapi/jsonreference + +License Identifier: Apache-2.0 + +#### github.com/go-openapi/swag + +License Identifier: Apache-2.0 + +#### github.com/gogo/protobuf + +License Identifier: BSD-3-Clause + +Copyright (c) 2013, The GoGo Authors. All rights reserved. + +Protocol Buffers for Go with Gadgets + +Go support for Protocol Buffers - Google's data interchange format + +Copyright 2010 The Go Authors. All rights reserved. +https://github.com/golang/protobuf + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/golang/protobuf + +License Identifier: BSD-3-Clause + +Copyright 2010 The Go Authors. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/google/btree + +License Identifier: Apache-2.0 + +#### github.com/google/gnostic-models + +License Identifier: Apache-2.0 + +#### github.com/google/gofuzz + +License Identifier: Apache-2.0 + +#### github.com/google/uuid + +License Identifier: BSD-3-Clause + +Copyright (c) 2009,2014 Google Inc. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +#### github.com/itchyny/timefmt-go + +License Identifier: MIT + +The MIT License (MIT) + +Copyright (c) 2020,2021 itchyny + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +#### github.com/josharian/intern + +License Identifier: MIT + +MIT License + +Copyright (c) 2019 Josh Bleecher Snyder + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +#### github.com/json-iterator/go + +License Identifier: MIT + +MIT License + +Copyright (c) 2016 json-iterator + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +#### github.com/mailru/easyjson + +Copyright (c) 2016 Mail.Ru Group + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +#### github.com/modern-go/concurrent + +License Identifier: Apache-2.0 + +#### github.com/modern-go/reflect2 + +License Identifier: Apache-2.0 + +#### github.com/munnerz/goautoneg + +License Identifier: BSD-3-Clause + +Copyright (c) 2011, Open Knowledge Foundation Ltd. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: + + Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + + Neither the name of the Open Knowledge Foundation Ltd. nor the + names of its contributors may be used to endorse or promote + products derived from this software without specific prior written + permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + #### github.com/pmezard/go-difflib +License Identifier: BSD-3-Clause + Copyright (c) 2013, Patrick Mezard All rights reserved. @@ -522,8 +932,22 @@ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#### github.com/prometheus/client_model + +License Identifier: Apache-2.0 + +#### github.com/prometheus/common + +License Identifier: Apache-2.0 + +#### github.com/prometheus/procfs + +License Identifier: Apache-2.0 + #### github.com/stretchr/objx +License Identifier: MIT + The MIT License Copyright (c) 2014 Stretchr, Inc. @@ -547,13 +971,59 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -#### gopkg.in/yaml.v3 +#### github.com/x448/float16 + +License Identifier: MIT -Apache License version 2.0 +MIT License -### golang.org/x/mod +Copyright (c) 2019 Montgomery Edwards⁴⁴⁸ and Faye Amacker -Copyright (c) 2009 The Go Authors. All rights reserved. +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +#### go.uber.org/multierr + +Copyright (c) 2017-2021 Uber Technologies, Inc. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. + +#### golang.org/x/exp + +License Identifier: BSD-3-Clause + +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -565,7 +1035,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. @@ -581,60 +1051,11 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -Subdependencies: -* `golang.org/x/crypto` -* `golang.org/x/tools` -* `golang.org/x/xerrors` - -### k8s.io/api - -Apache License version 2.0 - -### k8s.io/apimachinery - -Apache License version 2.0 - -Subdependencies: - -* `github.com/davecgh/go-spew` -* `github.com/docker/spdystream` -* `github.com/elazarl/goproxy` -* `github.com/evanphx/json-patch` -* `github.com/fsnotify/fsnotify` -* `github.com/gogo/protobuf` -* `github.com/golang/groupcache` -* `github.com/golang/protobuf` -* `github.com/google/go-cmp` -* `github.com/google/gofuzz` -* `github.com/google/uuid` -* `github.com/googleapis/gnostic` -* `github.com/hashicorp/golang-lru` -* `github.com/json-iterator/go` -* `github.com/modern-go/reflect2` -* `github.com/mxk/go-flowrate` -* `github.com/onsi/ginkgo` -* `github.com/onsi/gomega` -* `github.com/pkg/errors` -* `github.com/spf13/pflag` -* `github.com/stretchr/testify` -* `golang.org/x/net` -* `golang.org/x/sys` -* `golang.org/x/text` -* `google.golang.org/protobuf` -* `gopkg.in/inf.v0` -* `gopkg.in/yaml.v2` -* `k8s.io/klog/v2` -* `k8s.io/kube-openapi` -* `sigs.k8s.io/structured-merge-diff/v4` -* `sigs.k8s.io/yaml` +#### golang.org/x/net -#### github.com/docker/spdystream +License Identifier: BSD-3-Clause -Apache License version 2.0 - -#### github.com/elazarl/goproxy - -Copyright (c) 2012 Elazar Leibovich. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -646,7 +1067,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Elazar Leibovich. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. @@ -662,38 +1083,11 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/evanphx/json-patch - -Copyright (c) 2014, Evan Phoenix -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - -* Redistributions of source code must retain the above copyright notice, this - list of conditions and the following disclaimer. -* Redistributions in binary form must reproduce the above copyright notice, - this list of conditions and the following disclaimer in the documentation - and/or other materials provided with the distribution. -* Neither the name of the Evan Phoenix nor the names of its contributors - may be used to endorse or promote products derived from this software - without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE -FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, -OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#### golang.org/x/oauth2 -#### github.com/fsnotify/fsnotify +License Identifier: BSD-3-Clause -Copyright (c) 2012 The Go Authors. All rights reserved. -Copyright (c) 2012-2019 fsnotify Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -705,7 +1099,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. @@ -721,28 +1115,23 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/gogo/protobuf - -Copyright (c) 2013, The GoGo Authors. All rights reserved. - -Protocol Buffers for Go with Gadgets +#### golang.org/x/sync -Go support for Protocol Buffers - Google's data interchange format +License Identifier: BSD-3-Clause -Copyright 2010 The Go Authors. All rights reserved. -https://github.com/golang/protobuf +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright + * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above + * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. @@ -758,25 +1147,23 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/golang/groupcache +#### golang.org/x/sys -Apache License version 2.0 - -#### github.com/golang/protobuf +License Identifier: BSD-3-Clause -Copyright 2010 The Go Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright + * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above + * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. @@ -792,13 +1179,11 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/google/gofuzz - -Apache License version 2.0 +#### golang.org/x/term -#### github.com/google/uuid +License Identifier: BSD-3-Clause -Copyright (c) 2009,2014 Google Inc. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -810,7 +1195,7 @@ notice, this list of conditions and the following disclaimer. copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. - * Neither the name of Google Inc. nor the names of its + * Neither the name of Google LLC nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. @@ -826,122 +1211,89 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/googleapis/gnostic - -Apache License version 2.0 - -Subdependencies: - -* `github.com/docopt/docopt-go` -* `github.com/golang/protobuf` -* `github.com/stoewer/go-strcase` -* `google.golang.org/protobuf` -* `gopkg.in/check.v1` -* `gopkg.in/yaml.v3` - -##### github.com/docopt/docopt-go - -The MIT License (MIT) - -Copyright (c) 2013 Keith Batten -Copyright (c) 2016 David Irvine - -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of -the Software, and to permit persons to whom the Software is furnished to do so, -subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS -FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR -COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER -IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN -CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -##### github.com/stoewer/go-strcase - -The MIT License (MIT) - -Copyright (c) 2017, Adrian Stoewer - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +#### golang.org/x/text -#### github.com/hashicorp/golang-lru +License Identifier: BSD-3-Clause -Mozilla Public License, version 2.0 +Copyright 2009 The Go Authors. -#### github.com/json-iterator/go +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: -MIT License + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google LLC nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. -Copyright (c) 2016 json-iterator +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +#### golang.org/x/time -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +License Identifier: BSD-3-Clause -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +Copyright 2009 The Go Authors. -Subdependencies: +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: -* `github.com/modern-go/reflect2` + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google LLC nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. -##### github.com/modern-go/reflect2 +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -Apache License version 2.0 +#### golang.org/x/tools -#### github.com/mxk/go-flowrate +License Identifier: BSD-3-Clause -Copyright (c) 2014 The Go-FlowRate Authors. All rights reserved. +Copyright 2009 The Go Authors. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - * Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the - distribution. - - * Neither the name of the go-flowrate project nor the names of its - contributors may be used to endorse or promote products derived - from this software without specific prior written permission. + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google LLC nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT @@ -955,34 +1307,15 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/onsi/ginkgo -#### github.com/onsi/gomega - -Copyright (c) 2013-2014 Onsi Fakhouri - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +#### gomodules.xyz/jsonpatch/v2 -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. +License Identifier: Apache-2.0 -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +#### google.golang.org/protobuf -#### gopkg.in/inf.v0 +License Identifier: BSD-3-Clause -Copyright (c) 2012 Péter Surányi. Portions Copyright (c) 2009 The Go -Authors. All rights reserved. +Copyright (c) 2018 The Go Authors. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -1010,116 +1343,301 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/kubernetes-sigs/structured-merge-diff +#### gopkg.in/evanphx/json-patch.v4 -Apache License version 2.0 +License Identifier: BSD-3-Clause -### k8s.io/client-go - -Apache License version 2.0 - -Subdependencies: - -* `github.com/Azure/go-autorest/autorest` -* `github.com/Azure/go-autorest/autorest/adal` -* `github.com/davecgh/go-spew` -* `github.com/evanphx/json-patch` -* `github.com/gogo/protobuf` -* `github.com/golang/groupcache` -* `github.com/golang/protobuf` -* `github.com/google/go-cmp` -* `github.com/google/gofuzz` -* `github.com/google/uuid` -* `github.com/googleapis/gnostic` -* `github.com/gregjones/httpcache` -* `github.com/imdario/mergo` -* `github.com/peterbourgon/diskv` -* `github.com/spf13/pflag` -* `github.com/stretchr/testify` -* `golang.org/x/crypto` -* `golang.org/x/net` -* `golang.org/x/oauth2` -* `golang.org/x/time` -* `k8s.io/api` -* `k8s.io/apimachinery` -* `k8s.io/klog/v2` -* `k8s.io/utils` -* `sigs.k8s.io/yaml` - -#### github.com/Azure/go-autorest +Copyright (c) 2014, Evan Phoenix +All rights reserved. -Apache License version 2.0 +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: -Subdependencies: +* Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +* Neither the name of the Evan Phoenix nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. -* `contrib.go.opencensus.io/exporter/ocagent` -* `github.com/dgrijalva/jwt-go` -* `github.com/dimchansky/utfbom` -* `github.com/mitchellh/go-homedir` -* `github.com/stretchr/testify` -* `go.opencensus.io` -* `golang.org/x/crypto` +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -##### contrib.go.opencensus.io/ +#### gopkg.in/inf.v0 -Apache License version 2.0 +License Identifier: BSD-3-Clause -##### github.com/dgrijalva/jwt-go +Copyright (c) 2012 Péter Surányi. Portions Copyright (c) 2009 The Go +Authors. All rights reserved. -Copyright (c) 2012 Dave Grijalva +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are +met: -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: + * Redistributions of source code must retain the above copyright +notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above +copyright notice, this list of conditions and the following disclaimer +in the documentation and/or other materials provided with the +distribution. + * Neither the name of Google Inc. nor the names of its +contributors may be used to endorse or promote products derived from +this software without specific prior written permission. -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. +#### gopkg.in/yaml.v3 -##### github.com/dimchansky/utfbom +License Identifier: Apache-2.0 -Apache License version 2.0 +#### k8s.io/apiextensions-apiserver -##### go.opencensus.io +License Identifier: Apache-2.0 -Apache License version 2.0 +#### k8s.io/kube-openapi + +License Identifier: Apache-2.0 -#### github.com/gregjones/httpcache +#### k8s.io/utils + +License Identifier: Apache-2.0 -Copyright © 2012 Greg Jones (greg.jones@gmail.com) +#### sigs.k8s.io/json + +License Identifier: BSD-3-Clause -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the “Software”), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: +Files other than internal/golang/* licensed under: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright {yyyy} {name of copyright owner} + + 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. + + +------------------ + +internal/golang/* files licensed under: -#### github.com/imdario/mergo -Copyright (c) 2013 Dario Castañé. All rights reserved. -Copyright (c) 2012 The Go Authors. All rights reserved. +Copyright (c) 2009 The Go Authors. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are @@ -1147,219 +1665,107 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -#### github.com/peterbourgon/diskv +#### sigs.k8s.io/structured-merge-diff/v4 -Copyright (c) 2011-2012 Peter Bourgon +License Identifier: Apache-2.0 -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: +#### sigs.k8s.io/yaml -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. +License Identifier: Apache-2.0 -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +### github.com/aws/aws-sdk-go -Subdependencies: +License Identifier: Apache-2.0 -* `github.com/google/btree` +Subdependencies: +* `github.com/jmespath/go-jmespath` +* `golang.org/x/net` +* `golang.org/x/text` -##### github.com/google/btree +#### github.com/jmespath/go-jmespath -Apache License version 2.0 +License Identifier: Apache-2.0 -### sigs.k8s.io/controller-runtime +### github.com/aws/aws-sdk-go-v2 -Apache License version 2.0 +License Identifier: Apache-2.0 Subdependencies: +* `github.com/aws/smithy-go` -* `github.com/evanphx/json-patch` -* `github.com/fsnotify/fsnotify` -* `github.com/go-logr/logr` -* `github.com/go-logr/zapr` -* `github.com/onsi/ginkgo` -* `github.com/onsi/gomega` -* `github.com/prometheus/client_golang` -* `github.com/prometheus/client_model` -* `go.uber.org/goleak` -* `go.uber.org/zap` -* `golang.org/x/time` -* `gomodules.xyz/jsonpatch/v2` -* `k8s.io/api` -* `k8s.io/apiextensions-apiserver` -* `k8s.io/apimachinery` -* `k8s.io/client-go` -* `k8s.io/utils` -* `sigs.k8s.io/yaml` +#### github.com/aws/smithy-go -#### github.com/prometheus/client_golang +License Identifier: Apache-2.0 -Apaches License version 2.0 +### github.com/aws/aws-sdk-go-v2/service/s3 + +License Identifier: Apache-2.0 Subdependencies: +* `github.com/aws/aws-sdk-go-v2` +* `github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream` +* `github.com/aws/aws-sdk-go-v2/internal/configsources` +* `github.com/aws/aws-sdk-go-v2/internal/endpoints/v2` +* `github.com/aws/aws-sdk-go-v2/internal/v4a` +* `github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding` +* `github.com/aws/aws-sdk-go-v2/service/internal/checksum` +* `github.com/aws/aws-sdk-go-v2/service/internal/presigned-url` +* `github.com/aws/aws-sdk-go-v2/service/internal/s3shared` +* `github.com/aws/smithy-go` -* `github.com/beorn7/perks` -* `github.com/cespare/xxhash/v2` -* `github.com/golang/protobuf` -* `github.com/json-iterator/go` -* `github.com/prometheus/client_model` -* `github.com/prometheus/common` -* `github.com/prometheus/procfs` -* `golang.org/x/sys` +#### github.com/aws/aws-sdk-go-v2 -##### github.com/beorn7/perks +License Identifier: Apache-2.0 -Copyright (C) 2013 Blake Mizerany +#### github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +License Identifier: Apache-2.0 -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -##### github.com/cespare/xxhash -Copyright (c) 2016 Caleb Spare -MIT License +#### github.com/aws/aws-sdk-go-v2/internal/v4a -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: +License Identifier: Apache-2.0 -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -#### go.uber.org/goleak -#### go.uber.org/zap +#### github.com/aws/aws-sdk-go-v2/service/internal/checksum -The MIT License (MIT) +License Identifier: Apache-2.0 -Copyright (c) 2018 Uber Technologies, Inc. -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. +#### github.com/aws/aws-sdk-go-v2/service/internal/s3shared -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. +License Identifier: Apache-2.0 -### sigs.k8s.io/controller-tools +### github.com/aws/aws-sdk-go-v2/service/s3control -Apache License version 2.0 +License Identifier: Apache-2.0 Subdependencies: +* `github.com/aws/aws-sdk-go-v2` +* `github.com/aws/aws-sdk-go-v2/internal/configsources` +* `github.com/aws/aws-sdk-go-v2/internal/endpoints/v2` +* `github.com/aws/aws-sdk-go-v2/service/internal/s3shared` +* `github.com/aws/smithy-go` + + + -* `github.com/fatih/color` -* `github.com/gobuffalo/flect` -* `github.com/google/go-cmp` -* `github.com/onsi/ginkgo` -* `github.com/onsi/gomega` -* `github.com/spf13/cobra` -* `github.com/spf13/pflag` -* `golang.org/x/tools` -* `gopkg.in/yaml.v3` -* `k8s.io/api` -* `k8s.io/apiextensions-apiserver` -* `k8s.io/apimachinery` -* `sigs.k8s.io/yaml` -#### github.com/fatih/color -The MIT License (MIT) -Copyright (c) 2013 Fatih Arslan -Permission is hereby granted, free of charge, to any person obtaining a copy of -this software and associated documentation files (the "Software"), to deal in -the Software without restriction, including without limitation the rights to -use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -of the Software, and to permit persons to whom the Software is furnished to do -so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. -Subdependencies: -* `github.com/mattn/go-colorable` -* `github.com/mattn/go-isatty` -# github.com/mattn/go-colorable -# github.com/mattn/go-isatty -The MIT License (MIT) -Copyright (c) 2016 Yasuhiro Matsumoto -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/apis/v1alpha1/ack-generate-metadata.yaml b/apis/v1alpha1/ack-generate-metadata.yaml index e9def4c..4224c0a 100755 --- a/apis/v1alpha1/ack-generate-metadata.yaml +++ b/apis/v1alpha1/ack-generate-metadata.yaml @@ -1,13 +1,13 @@ ack_generate_info: - build_date: "2025-09-19T17:20:43Z" - build_hash: 6b4211163dcc34776b01da9a18217bac0f4103fd - go_version: go1.24.6 - version: v0.52.0 -api_directory_checksum: 2108338a86d704419192e545c0bfb433bab8c836 + build_date: "2025-10-29T15:19:17Z" + build_hash: eaabefb6bd7b2be8a1baf4478f22b3310e6921c8 + go_version: go1.25.3 + version: v0.52.0-6-geaabefb-dirty +api_directory_checksum: 0215f0e48eb84dd4b61045aee4ca703d5bf97304 api_version: v1alpha1 aws_sdk_go_version: v1.32.6 generator_config_info: - file_checksum: 00a96da29786586c7a3a59666d5546468e616b48 + file_checksum: cd2274c70e78e904884fa8869c5b9fbacc4a0c53 original_file_name: generator.yaml last_modification: reason: API generation diff --git a/apis/v1alpha1/generator.yaml b/apis/v1alpha1/generator.yaml index 5997d16..6dee8a8 100644 --- a/apis/v1alpha1/generator.yaml +++ b/apis/v1alpha1/generator.yaml @@ -12,11 +12,11 @@ ignore: - "VersioningConfiguration.MFADelete" # This subfield struct has no members... - "NotificationConfiguration.EventBridgeConfiguration" - - CreateBucketInput.CreateBucketConfiguration.Location - - CreateBucketInput.CreateBucketConfiguration.Bucket - LoggingEnabled.TargetObjectKeyFormat resources: Bucket: + find_operation: + custom_method_name: customFindBucket fields: Name: is_primary_key: true @@ -58,6 +58,12 @@ resources: # Forcing CRD field to "uRI" to avoid breaking change following # fix in aws-controller-k8s/pkg dependency for URI -> uri. go_tag: json:"uRI,omitempty" + CreateBucketConfiguration.Bucket.Type: + # Override json tag to use "type" instead of "type_" to avoid underscore in CRD + go_tag: json:"type,omitempty" + CreateBucketConfiguration.Location.Type: + # Override json tag to use "type" instead of "type_" to avoid underscore in CRD + go_tag: json:"type,omitempty" Metrics: custom_field: list_of: MetricsConfiguration diff --git a/apis/v1alpha1/types.go b/apis/v1alpha1/types.go index e685dde..eb2e67c 100644 --- a/apis/v1alpha1/types.go +++ b/apis/v1alpha1/types.go @@ -104,6 +104,16 @@ type AnalyticsS3BucketDestination struct { Prefix *string `json:"prefix,omitempty"` } +// Specifies the information about the bucket that will be created. For more +// information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) +// in the Amazon S3 User Guide. +// +// This functionality is only supported by directory buckets. +type BucketInfo struct { + DataRedundancy *string `json:"dataRedundancy,omitempty"` + Type *string `json:"type,omitempty"` +} + // Specifies the lifecycle configuration for objects in an Amazon S3 bucket. // For more information, see Object Lifecycle Management (https://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html) // in the Amazon S3 User Guide. @@ -165,7 +175,21 @@ type Condition struct { // The configuration information for the bucket. type CreateBucketConfiguration struct { - LocationConstraint *string `json:"locationConstraint,omitempty"` + // Specifies the information about the bucket that will be created. For more + // information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) + // in the Amazon S3 User Guide. + // + // This functionality is only supported by directory buckets. + Bucket *BucketInfo `json:"bucket,omitempty"` + // Specifies the location where the bucket will be created. + // + // For directory buckets, the location type is Availability Zone or Local Zone. + // For more information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) + // in the Amazon S3 User Guide. + // + // This functionality is only supported by directory buckets. + Location *LocationInfo `json:"location,omitempty"` + LocationConstraint *string `json:"locationConstraint,omitempty"` } // The container element for optionally specifying the default Object Lock retention @@ -501,6 +525,18 @@ type Location struct { Tagging *Tagging `json:"tagging,omitempty"` } +// Specifies the location where the bucket will be created. +// +// For directory buckets, the location type is Availability Zone or Local Zone. +// For more information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) +// in the Amazon S3 User Guide. +// +// This functionality is only supported by directory buckets. +type LocationInfo struct { + Name *string `json:"name,omitempty"` + Type *string `json:"type,omitempty"` +} + // Describes where logs are stored and the prefix that Amazon S3 assigns to // all log object keys for a bucket. For more information, see PUT Bucket logging // (https://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTlogging.html) diff --git a/apis/v1alpha1/zz_generated.deepcopy.go b/apis/v1alpha1/zz_generated.deepcopy.go index 1d45253..222e386 100644 --- a/apis/v1alpha1/zz_generated.deepcopy.go +++ b/apis/v1alpha1/zz_generated.deepcopy.go @@ -277,6 +277,31 @@ func (in *Bucket) DeepCopyObject() runtime.Object { return nil } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *BucketInfo) DeepCopyInto(out *BucketInfo) { + *out = *in + if in.DataRedundancy != nil { + in, out := &in.DataRedundancy, &out.DataRedundancy + *out = new(string) + **out = **in + } + if in.Type != nil { + in, out := &in.Type, &out.Type + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new BucketInfo. +func (in *BucketInfo) DeepCopy() *BucketInfo { + if in == nil { + return nil + } + out := new(BucketInfo) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *BucketLifecycleConfiguration) DeepCopyInto(out *BucketLifecycleConfiguration) { *out = *in @@ -742,6 +767,16 @@ func (in *Condition) DeepCopy() *Condition { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *CreateBucketConfiguration) DeepCopyInto(out *CreateBucketConfiguration) { *out = *in + if in.Bucket != nil { + in, out := &in.Bucket, &out.Bucket + *out = new(BucketInfo) + (*in).DeepCopyInto(*out) + } + if in.Location != nil { + in, out := &in.Location, &out.Location + *out = new(LocationInfo) + (*in).DeepCopyInto(*out) + } if in.LocationConstraint != nil { in, out := &in.LocationConstraint, &out.LocationConstraint *out = new(string) @@ -1686,6 +1721,31 @@ func (in *Location) DeepCopy() *Location { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *LocationInfo) DeepCopyInto(out *LocationInfo) { + *out = *in + if in.Name != nil { + in, out := &in.Name, &out.Name + *out = new(string) + **out = **in + } + if in.Type != nil { + in, out := &in.Type, &out.Type + *out = new(string) + **out = **in + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LocationInfo. +func (in *LocationInfo) DeepCopy() *LocationInfo { + if in == nil { + return nil + } + out := new(LocationInfo) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *LoggingEnabled) DeepCopyInto(out *LoggingEnabled) { *out = *in diff --git a/config/crd/bases/s3.services.k8s.aws_buckets.yaml b/config/crd/bases/s3.services.k8s.aws_buckets.yaml index e5e4990..439bcdc 100644 --- a/config/crd/bases/s3.services.k8s.aws_buckets.yaml +++ b/config/crd/bases/s3.services.k8s.aws_buckets.yaml @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.16.2 + controller-gen.kubebuilder.io/version: v0.19.0 name: buckets.s3.services.k8s.aws spec: group: s3.services.k8s.aws @@ -171,6 +171,34 @@ spec: createBucketConfiguration: description: The configuration information for the bucket. properties: + bucket: + description: |- + Specifies the information about the bucket that will be created. For more + information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) + in the Amazon S3 User Guide. + + This functionality is only supported by directory buckets. + properties: + dataRedundancy: + type: string + type: + type: string + type: object + location: + description: |- + Specifies the location where the bucket will be created. + + For directory buckets, the location type is Availability Zone or Local Zone. + For more information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) + in the Amazon S3 User Guide. + + This functionality is only supported by directory buckets. + properties: + name: + type: string + type: + type: string + type: object locationConstraint: type: string type: object diff --git a/generator.yaml b/generator.yaml index 5997d16..6dee8a8 100644 --- a/generator.yaml +++ b/generator.yaml @@ -12,11 +12,11 @@ ignore: - "VersioningConfiguration.MFADelete" # This subfield struct has no members... - "NotificationConfiguration.EventBridgeConfiguration" - - CreateBucketInput.CreateBucketConfiguration.Location - - CreateBucketInput.CreateBucketConfiguration.Bucket - LoggingEnabled.TargetObjectKeyFormat resources: Bucket: + find_operation: + custom_method_name: customFindBucket fields: Name: is_primary_key: true @@ -58,6 +58,12 @@ resources: # Forcing CRD field to "uRI" to avoid breaking change following # fix in aws-controller-k8s/pkg dependency for URI -> uri. go_tag: json:"uRI,omitempty" + CreateBucketConfiguration.Bucket.Type: + # Override json tag to use "type" instead of "type_" to avoid underscore in CRD + go_tag: json:"type,omitempty" + CreateBucketConfiguration.Location.Type: + # Override json tag to use "type" instead of "type_" to avoid underscore in CRD + go_tag: json:"type,omitempty" Metrics: custom_field: list_of: MetricsConfiguration diff --git a/go.mod b/go.mod index b364132..84672cd 100644 --- a/go.mod +++ b/go.mod @@ -7,9 +7,10 @@ toolchain go1.24.1 require ( github.com/aws-controllers-k8s/runtime v0.52.0 github.com/aws/aws-sdk-go v1.49.0 - github.com/aws/aws-sdk-go-v2 v1.34.0 + github.com/aws/aws-sdk-go-v2 v1.39.3 github.com/aws/aws-sdk-go-v2/service/s3 v1.74.1 - github.com/aws/smithy-go v1.22.2 + github.com/aws/aws-sdk-go-v2/service/s3control v1.66.4 + github.com/aws/smithy-go v1.23.1 github.com/go-logr/logr v1.4.2 github.com/pkg/errors v0.9.1 github.com/spf13/pflag v1.0.5 @@ -25,14 +26,14 @@ require ( github.com/aws/aws-sdk-go-v2/config v1.28.6 // indirect github.com/aws/aws-sdk-go-v2/credentials v1.17.47 // indirect github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.21 // indirect - github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.29 // indirect - github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.29 // indirect + github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.10 // indirect + github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.10 // indirect github.com/aws/aws-sdk-go-v2/internal/ini v1.8.1 // indirect github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.29 // indirect github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.12.2 // indirect github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.5.3 // indirect github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.12.10 // indirect - github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.18.10 // indirect + github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.10 // indirect github.com/aws/aws-sdk-go-v2/service/sso v1.24.7 // indirect github.com/aws/aws-sdk-go-v2/service/ssooidc v1.28.6 // indirect github.com/aws/aws-sdk-go-v2/service/sts v1.33.2 // indirect diff --git a/go.sum b/go.sum index 77d54b6..e311dd3 100644 --- a/go.sum +++ b/go.sum @@ -2,8 +2,8 @@ github.com/aws-controllers-k8s/runtime v0.52.0 h1:Q5UIAn6SSBr60t/DiU/zr6NLBlUuK2 github.com/aws-controllers-k8s/runtime v0.52.0/go.mod h1:OkUJN+Ds799JLYZsMJrO2vDJ4snxUeHK2MgrQHbU+Qc= github.com/aws/aws-sdk-go v1.49.0 h1:g9BkW1fo9GqKfwg2+zCD+TW/D36Ux+vtfJ8guF4AYmY= github.com/aws/aws-sdk-go v1.49.0/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= -github.com/aws/aws-sdk-go-v2 v1.34.0 h1:9iyL+cjifckRGEVpRKZP3eIxVlL06Qk1Tk13vreaVQU= -github.com/aws/aws-sdk-go-v2 v1.34.0/go.mod h1:JgstGg0JjWU1KpVJjD5H0y0yyAIpSdKEq556EI6yOOM= +github.com/aws/aws-sdk-go-v2 v1.39.3 h1:h7xSsanJ4EQJXG5iuW4UqgP7qBopLpj84mpkNx3wPjM= +github.com/aws/aws-sdk-go-v2 v1.39.3/go.mod h1:yWSxrnioGUZ4WVv9TgMrNUeLV3PFESn/v+6T/Su8gnM= github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.8 h1:zAxi9p3wsZMIaVCdoiQp2uZ9k1LsZvmAnoTBeZPXom0= github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.8/go.mod h1:3XkePX5dSaxveLAYY7nsbsZZrKxCyEuE5pM4ziFxyGg= github.com/aws/aws-sdk-go-v2/config v1.28.6 h1:D89IKtGrs/I3QXOLNTH93NJYtDhm8SYa9Q5CsPShmyo= @@ -12,10 +12,10 @@ github.com/aws/aws-sdk-go-v2/credentials v1.17.47 h1:48bA+3/fCdi2yAwVt+3COvmatZ6 github.com/aws/aws-sdk-go-v2/credentials v1.17.47/go.mod h1:+KdckOejLW3Ks3b0E3b5rHsr2f9yuORBum0WPnE5o5w= github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.21 h1:AmoU1pziydclFT/xRV+xXE/Vb8fttJCLRPv8oAkprc0= github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.21/go.mod h1:AjUdLYe4Tgs6kpH4Bv7uMZo7pottoyHMn4eTcIcneaY= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.29 h1:Ej0Rf3GMv50Qh4G4852j2djtoDb7AzQ7MuQeFHa3D70= -github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.29/go.mod h1:oeNTC7PwJNoM5AznVr23wxhLnuJv0ZDe5v7w0wqIs9M= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.29 h1:6e8a71X+9GfghragVevC5bZqvATtc3mAMgxpSNbgzF0= -github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.29/go.mod h1:c4jkZiQ+BWpNqq7VtrxjwISrLrt/VvPq3XiopkUIolI= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.10 h1:mj/bdWleWEh81DtpdHKkw41IrS+r3uw1J/VQtbwYYp8= +github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.10/go.mod h1:7+oEMxAZWP8gZCyjcm9VicI0M61Sx4DJtcGfKYv2yKQ= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.10 h1:wh+/mn57yhUrFtLIxyFPh2RgxgQz/u+Yrf7hiHGHqKY= +github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.10/go.mod h1:7zirD+ryp5gitJJ2m1BBux56ai8RIRDykXZrJSp540w= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.1 h1:VaRN3TlFdd6KxX1x3ILT5ynH6HvKgqdiXoTxAF4HQcQ= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.1/go.mod h1:FbtygfRFze9usAadmnGJNc8KsP346kEe+y2/oyhGAGc= github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.29 h1:g9OUETuxA8i/Www5Cby0R3WSTe7ppFTZXHVLNskNS4w= @@ -26,18 +26,20 @@ github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.5.3 h1:EP1ITDgYVPM2dL1 github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.5.3/go.mod h1:5lWNWeAgWenJ/BZ/CP9k9DjLbC0pjnM045WjXRPPi14= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.12.10 h1:hN4yJBGswmFTOVYqmbz1GBs9ZMtQe8SrYxPwrkrlRv8= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.12.10/go.mod h1:TsxON4fEZXyrKY+D+3d2gSTyJkGORexIYab9PTf56DA= -github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.18.10 h1:fXoWC2gi7tdJYNTPnnlSGzEVwewUchOi8xVq/dkg8Qs= -github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.18.10/go.mod h1:cvzBApD5dVazHU8C2rbBQzzzsKc8m5+wNJ9mCRZLKPc= +github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.10 h1:DA+Hl5adieRyFvE7pCvBWm3VOZTRexGVkXw33SUqNoY= +github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.19.10/go.mod h1:L+A89dH3/gr8L4ecrdzuXUYd1znoko6myzndVGZx/DA= github.com/aws/aws-sdk-go-v2/service/s3 v1.74.1 h1:9LawY3cDJ3HE+v2GMd5SOkNLDwgN4K7TsCjyVBYu/L4= github.com/aws/aws-sdk-go-v2/service/s3 v1.74.1/go.mod h1:hHnELVnIHltd8EOF3YzahVX6F6y2C6dNqpRj1IMkS5I= +github.com/aws/aws-sdk-go-v2/service/s3control v1.66.4 h1:crP9qsvLlgtGDH8/6Rm8IbyApuP0b9EblY2ZEM47Enw= +github.com/aws/aws-sdk-go-v2/service/s3control v1.66.4/go.mod h1:ghGid4gQ8PYl3B8ip/b25+4yTHzvBa1GvFJ/r/i2CI4= github.com/aws/aws-sdk-go-v2/service/sso v1.24.7 h1:rLnYAfXQ3YAccocshIH5mzNNwZBkBo+bP6EhIxak6Hw= github.com/aws/aws-sdk-go-v2/service/sso v1.24.7/go.mod h1:ZHtuQJ6t9A/+YDuxOLnbryAmITtr8UysSny3qcyvJTc= github.com/aws/aws-sdk-go-v2/service/ssooidc v1.28.6 h1:JnhTZR3PiYDNKlXy50/pNeix9aGMo6lLpXwJ1mw8MD4= github.com/aws/aws-sdk-go-v2/service/ssooidc v1.28.6/go.mod h1:URronUEGfXZN1VpdktPSD1EkAL9mfrV+2F4sjH38qOY= github.com/aws/aws-sdk-go-v2/service/sts v1.33.2 h1:s4074ZO1Hk8qv65GqNXqDjmkf4HSQqJukaLuuW0TpDA= github.com/aws/aws-sdk-go-v2/service/sts v1.33.2/go.mod h1:mVggCnIWoM09jP71Wh+ea7+5gAp53q+49wDFs1SW5z8= -github.com/aws/smithy-go v1.22.2 h1:6D9hW43xKFrRx/tXXfAlIZc4JI+yQe6snnWcQyxSyLQ= -github.com/aws/smithy-go v1.22.2/go.mod h1:irrKGvNn1InZwb2d7fkIRNucdfwR8R+Ts3wxYa/cJHg= +github.com/aws/smithy-go v1.23.1 h1:sLvcH6dfAFwGkHLZ7dGiYF7aK6mg4CgKA/iDKjLDt9M= +github.com/aws/smithy-go v1.23.1/go.mod h1:LEj2LM3rBRQJxPZTB4KuzZkaZYnZPnvgIhb4pu07mx0= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= diff --git a/helm/crds/s3.services.k8s.aws_buckets.yaml b/helm/crds/s3.services.k8s.aws_buckets.yaml index 39edc94..23107dc 100644 --- a/helm/crds/s3.services.k8s.aws_buckets.yaml +++ b/helm/crds/s3.services.k8s.aws_buckets.yaml @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.16.2 + controller-gen.kubebuilder.io/version: v0.19.0 name: buckets.s3.services.k8s.aws spec: group: s3.services.k8s.aws @@ -171,6 +171,34 @@ spec: createBucketConfiguration: description: The configuration information for the bucket. properties: + bucket: + description: |- + Specifies the information about the bucket that will be created. For more + information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) + in the Amazon S3 User Guide. + + This functionality is only supported by directory buckets. + properties: + dataRedundancy: + type: string + type: + type: string + type: object + location: + description: |- + Specifies the location where the bucket will be created. + + For directory buckets, the location type is Availability Zone or Local Zone. + For more information about directory buckets, see Directory buckets (https://docs.aws.amazon.com/AmazonS3/latest/userguide/directory-buckets-overview.html) + in the Amazon S3 User Guide. + + This functionality is only supported by directory buckets. + properties: + name: + type: string + type: + type: string + type: object locationConstraint: type: string type: object diff --git a/helm/crds/services.k8s.aws_adoptedresources.yaml b/helm/crds/services.k8s.aws_adoptedresources.yaml index b7be322..d6cdd10 100644 --- a/helm/crds/services.k8s.aws_adoptedresources.yaml +++ b/helm/crds/services.k8s.aws_adoptedresources.yaml @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.16.2 + controller-gen.kubebuilder.io/version: v0.19.0 name: adoptedresources.services.k8s.aws spec: group: services.k8s.aws diff --git a/helm/crds/services.k8s.aws_fieldexports.yaml b/helm/crds/services.k8s.aws_fieldexports.yaml index 49b4f38..6e2c61e 100644 --- a/helm/crds/services.k8s.aws_fieldexports.yaml +++ b/helm/crds/services.k8s.aws_fieldexports.yaml @@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: annotations: - controller-gen.kubebuilder.io/version: v0.16.2 + controller-gen.kubebuilder.io/version: v0.19.0 name: fieldexports.services.k8s.aws spec: group: services.k8s.aws diff --git a/pkg/resource/bucket/delta.go b/pkg/resource/bucket/delta.go index deee43a..4d607d3 100644 --- a/pkg/resource/bucket/delta.go +++ b/pkg/resource/bucket/delta.go @@ -83,6 +83,42 @@ func newResourceDelta( if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration, b.ko.Spec.CreateBucketConfiguration) { delta.Add("Spec.CreateBucketConfiguration", a.ko.Spec.CreateBucketConfiguration, b.ko.Spec.CreateBucketConfiguration) } else if a.ko.Spec.CreateBucketConfiguration != nil && b.ko.Spec.CreateBucketConfiguration != nil { + if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.Bucket, b.ko.Spec.CreateBucketConfiguration.Bucket) { + delta.Add("Spec.CreateBucketConfiguration.Bucket", a.ko.Spec.CreateBucketConfiguration.Bucket, b.ko.Spec.CreateBucketConfiguration.Bucket) + } else if a.ko.Spec.CreateBucketConfiguration.Bucket != nil && b.ko.Spec.CreateBucketConfiguration.Bucket != nil { + if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy, b.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy) { + delta.Add("Spec.CreateBucketConfiguration.Bucket.DataRedundancy", a.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy, b.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy) + } else if a.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy != nil && b.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy != nil { + if *a.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy != *b.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy { + delta.Add("Spec.CreateBucketConfiguration.Bucket.DataRedundancy", a.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy, b.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy) + } + } + if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.Bucket.Type, b.ko.Spec.CreateBucketConfiguration.Bucket.Type) { + delta.Add("Spec.CreateBucketConfiguration.Bucket.Type", a.ko.Spec.CreateBucketConfiguration.Bucket.Type, b.ko.Spec.CreateBucketConfiguration.Bucket.Type) + } else if a.ko.Spec.CreateBucketConfiguration.Bucket.Type != nil && b.ko.Spec.CreateBucketConfiguration.Bucket.Type != nil { + if *a.ko.Spec.CreateBucketConfiguration.Bucket.Type != *b.ko.Spec.CreateBucketConfiguration.Bucket.Type { + delta.Add("Spec.CreateBucketConfiguration.Bucket.Type", a.ko.Spec.CreateBucketConfiguration.Bucket.Type, b.ko.Spec.CreateBucketConfiguration.Bucket.Type) + } + } + } + if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.Location, b.ko.Spec.CreateBucketConfiguration.Location) { + delta.Add("Spec.CreateBucketConfiguration.Location", a.ko.Spec.CreateBucketConfiguration.Location, b.ko.Spec.CreateBucketConfiguration.Location) + } else if a.ko.Spec.CreateBucketConfiguration.Location != nil && b.ko.Spec.CreateBucketConfiguration.Location != nil { + if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.Location.Name, b.ko.Spec.CreateBucketConfiguration.Location.Name) { + delta.Add("Spec.CreateBucketConfiguration.Location.Name", a.ko.Spec.CreateBucketConfiguration.Location.Name, b.ko.Spec.CreateBucketConfiguration.Location.Name) + } else if a.ko.Spec.CreateBucketConfiguration.Location.Name != nil && b.ko.Spec.CreateBucketConfiguration.Location.Name != nil { + if *a.ko.Spec.CreateBucketConfiguration.Location.Name != *b.ko.Spec.CreateBucketConfiguration.Location.Name { + delta.Add("Spec.CreateBucketConfiguration.Location.Name", a.ko.Spec.CreateBucketConfiguration.Location.Name, b.ko.Spec.CreateBucketConfiguration.Location.Name) + } + } + if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.Location.Type, b.ko.Spec.CreateBucketConfiguration.Location.Type) { + delta.Add("Spec.CreateBucketConfiguration.Location.Type", a.ko.Spec.CreateBucketConfiguration.Location.Type, b.ko.Spec.CreateBucketConfiguration.Location.Type) + } else if a.ko.Spec.CreateBucketConfiguration.Location.Type != nil && b.ko.Spec.CreateBucketConfiguration.Location.Type != nil { + if *a.ko.Spec.CreateBucketConfiguration.Location.Type != *b.ko.Spec.CreateBucketConfiguration.Location.Type { + delta.Add("Spec.CreateBucketConfiguration.Location.Type", a.ko.Spec.CreateBucketConfiguration.Location.Type, b.ko.Spec.CreateBucketConfiguration.Location.Type) + } + } + } if ackcompare.HasNilDifference(a.ko.Spec.CreateBucketConfiguration.LocationConstraint, b.ko.Spec.CreateBucketConfiguration.LocationConstraint) { delta.Add("Spec.CreateBucketConfiguration.LocationConstraint", a.ko.Spec.CreateBucketConfiguration.LocationConstraint, b.ko.Spec.CreateBucketConfiguration.LocationConstraint) } else if a.ko.Spec.CreateBucketConfiguration.LocationConstraint != nil && b.ko.Spec.CreateBucketConfiguration.LocationConstraint != nil { diff --git a/pkg/resource/bucket/hook.go b/pkg/resource/bucket/hook.go index a423f58..0112762 100644 --- a/pkg/resource/bucket/hook.go +++ b/pkg/resource/bucket/hook.go @@ -20,6 +20,7 @@ import ( "github.com/pkg/errors" + ackv1alpha1 "github.com/aws-controllers-k8s/runtime/apis/core/v1alpha1" ackcompare "github.com/aws-controllers-k8s/runtime/pkg/compare" ackerr "github.com/aws-controllers-k8s/runtime/pkg/errors" ackrtlog "github.com/aws-controllers-k8s/runtime/pkg/runtime/log" @@ -27,6 +28,9 @@ import ( "github.com/aws/aws-sdk-go-v2/aws" svcsdk "github.com/aws/aws-sdk-go-v2/service/s3" svcsdktypes "github.com/aws/aws-sdk-go-v2/service/s3/types" + "github.com/aws/aws-sdk-go-v2/service/s3control" + s3controltypes "github.com/aws/aws-sdk-go-v2/service/s3control/types" + smithy "github.com/aws/smithy-go" ) // bucketARN returns the ARN of the S3 bucket with the given name. @@ -39,7 +43,13 @@ func bucketARN(bucketName string) string { // NOTE(a-hilaly): Other parts of ACK also use this default partition // e.g the generated function `ARNFromName` also uses `aws` as the // default partition. - return fmt.Sprintf("arn:aws:s3:::%s", bucketName) + var arnFormat string + if IsDirectoryBucketName(bucketName) { + arnFormat = "arn:aws:s3-express:::%s" + } else { + arnFormat = "arn:aws:s3:::%s" + } + return fmt.Sprintf(arnFormat, bucketName) } var ( @@ -70,29 +80,120 @@ const ( const ErrSyncingPutProperty = "Error syncing property '%s'" +// Returns a terminal error if unsupported fields are detected. +func validateDirectoryBucketSpec(ko *svcapitypes.Bucket) error { + if ko.Spec.Name == nil || !IsDirectoryBucketName(*ko.Spec.Name) { + return nil + } + + var unsupportedFields []string + + if ko.Spec.Accelerate != nil { + unsupportedFields = append(unsupportedFields, "Accelerate") + } + if len(ko.Spec.Analytics) > 0 { + unsupportedFields = append(unsupportedFields, "Analytics") + } + if ko.Spec.ACL != nil { + unsupportedFields = append(unsupportedFields, "ACL") + } + if ko.Spec.GrantFullControl != nil { + unsupportedFields = append(unsupportedFields, "GrantFullControl") + } + if ko.Spec.GrantRead != nil { + unsupportedFields = append(unsupportedFields, "GrantRead") + } + if ko.Spec.GrantReadACP != nil { + unsupportedFields = append(unsupportedFields, "GrantReadACP") + } + if ko.Spec.GrantWrite != nil { + unsupportedFields = append(unsupportedFields, "GrantWrite") + } + if ko.Spec.GrantWriteACP != nil { + unsupportedFields = append(unsupportedFields, "GrantWriteACP") + } + if ko.Spec.CORS != nil { + unsupportedFields = append(unsupportedFields, "CORS") + } + if len(ko.Spec.IntelligentTiering) > 0 { + unsupportedFields = append(unsupportedFields, "IntelligentTiering") + } + if len(ko.Spec.Inventory) > 0 { + unsupportedFields = append(unsupportedFields, "Inventory") + } + if ko.Spec.Lifecycle != nil { + unsupportedFields = append(unsupportedFields, "Lifecycle") + } + if ko.Spec.Logging != nil { + unsupportedFields = append(unsupportedFields, "Logging") + } + if len(ko.Spec.Metrics) > 0 { + unsupportedFields = append(unsupportedFields, "Metrics") + } + if ko.Spec.Notification != nil { + unsupportedFields = append(unsupportedFields, "Notification") + } + if ko.Spec.OwnershipControls != nil { + unsupportedFields = append(unsupportedFields, "OwnershipControls") + } + if ko.Spec.PublicAccessBlock != nil { + unsupportedFields = append(unsupportedFields, "PublicAccessBlock") + } + if ko.Spec.Replication != nil { + unsupportedFields = append(unsupportedFields, "Replication") + } + if ko.Spec.RequestPayment != nil { + unsupportedFields = append(unsupportedFields, "RequestPayment") + } + if ko.Spec.Versioning != nil { + unsupportedFields = append(unsupportedFields, "Versioning") + } + if ko.Spec.Website != nil { + unsupportedFields = append(unsupportedFields, "Website") + } + + if len(unsupportedFields) > 0 { + return ackerr.NewTerminalError(fmt.Errorf( + "directory buckets do not support the following fields: %s. "+ + "Please modify your bucket specification to valid Directory Bucket configurations. "+ + "See https://docs.aws.amazon.com/AmazonS3/latest/userguide/s3-express-differences.html", + strings.Join(unsupportedFields, ", "), + )) + } + + return nil +} + func (rm *resourceManager) createPutFields( ctx context.Context, r *resource, ) error { + // Check if this is a directory bucket to skip unsupported operations + isDirectoryBucket := r.ko.Spec.Name != nil && IsDirectoryBucketName(*r.ko.Spec.Name) + // Other configuration options (Replication) require versioning to be // enabled before they can be configured - if r.ko.Spec.Versioning != nil { + // Versioning is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.Versioning != nil { if err := rm.syncVersioning(ctx, r); err != nil { return err } } - if r.ko.Spec.Accelerate != nil { + // Accelerate is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.Accelerate != nil { if err := rm.syncAccelerate(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Accelerate") } } - if len(r.ko.Spec.Analytics) != 0 { + // Analytics is not supported for directory buckets + if !isDirectoryBucket && len(r.ko.Spec.Analytics) != 0 { if err := rm.syncAnalytics(ctx, r, nil); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Analytics") } } - if r.ko.Spec.CORS != nil { + // CORS is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.CORS != nil { if err := rm.syncCORS(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "CORS") } @@ -102,12 +203,14 @@ func (rm *resourceManager) createPutFields( return errors.Wrapf(err, ErrSyncingPutProperty, "Encryption") } } - if len(r.ko.Spec.IntelligentTiering) != 0 { + // Intelligent Tiering is not supported for directory buckets + if !isDirectoryBucket && len(r.ko.Spec.IntelligentTiering) != 0 { if err := rm.syncIntelligentTiering(ctx, r, nil); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "IntelligentTiering") } } - if len(r.ko.Spec.Inventory) != 0 { + // Inventory is not supported for directory buckets + if !isDirectoryBucket && len(r.ko.Spec.Inventory) != 0 { if err := rm.syncInventory(ctx, r, nil); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Inventory") } @@ -117,29 +220,33 @@ func (rm *resourceManager) createPutFields( return errors.Wrapf(err, ErrSyncingPutProperty, "Lifecycle") } } - if r.ko.Spec.Logging != nil { + // Logging is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.Logging != nil { if err := rm.syncLogging(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Logging") } } - if len(r.ko.Spec.Metrics) != 0 { + // Metrics is not supported for directory buckets + if !isDirectoryBucket && len(r.ko.Spec.Metrics) != 0 { if err := rm.syncMetrics(ctx, r, nil); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Metrics") } } - if r.ko.Spec.Notification != nil { + // Notification is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.Notification != nil { if err := rm.syncNotification(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Notification") } } - if r.ko.Spec.OwnershipControls != nil { + // Ownership controls are not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.OwnershipControls != nil { if err := rm.syncOwnershipControls(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "OwnershipControls") } } // PublicAccessBlock may need to be set in order to use Policy, so sync it - // first - if r.ko.Spec.PublicAccessBlock != nil { + // first. Not supported for directory buckets. + if !isDirectoryBucket && r.ko.Spec.PublicAccessBlock != nil { if err := rm.syncPublicAccessBlock(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "PublicAccessBlock") } @@ -149,22 +256,26 @@ func (rm *resourceManager) createPutFields( return errors.Wrapf(err, ErrSyncingPutProperty, "Policy") } } - if r.ko.Spec.Replication != nil { + // Replication is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.Replication != nil { if err := rm.syncReplication(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Replication") } } - if r.ko.Spec.RequestPayment != nil { + // Request payment is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.RequestPayment != nil { if err := rm.syncRequestPayment(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "RequestPayment") } } + // Tagging is supported for both general-purpose and directory buckets if r.ko.Spec.Tagging != nil { if err := rm.syncTagging(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Tagging") } } - if r.ko.Spec.Website != nil { + // Website is not supported for directory buckets + if !isDirectoryBucket && r.ko.Spec.Website != nil { if err := rm.syncWebsite(ctx, r); err != nil { return errors.Wrapf(err, ErrSyncingPutProperty, "Website") } @@ -184,33 +295,45 @@ func (rm *resourceManager) customUpdateBucket( exit := rlog.Trace("rm.customUpdateBucket") defer exit(err) + // Validate directory bucket configuration + if err := validateDirectoryBucketSpec(desired.ko); err != nil { + return nil, err + } + // Merge in the information we read from the API call above to the copy of // the original Kubernetes object we passed to the function ko := desired.ko.DeepCopy() rm.setStatusDefaults(ko) - if delta.DifferentAt("Spec.Accelerate") { + // Check if this is a directory bucket to skip unsupported operations + isDirectoryBucket := desired.ko.Spec.Name != nil && IsDirectoryBucketName(*desired.ko.Spec.Name) + + // Accelerate is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Accelerate") { if err := rm.syncAccelerate(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Accelerate") } } - if delta.DifferentAt("Spec.Analytics") { + // Analytics is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Analytics") { if err := rm.syncAnalytics(ctx, desired, latest); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Analytics") } } - if delta.DifferentAt("Spec.ACL") || + // ACL operations are not supported for directory buckets + if !isDirectoryBucket && (delta.DifferentAt("Spec.ACL") || delta.DifferentAt("Spec.GrantFullControl") || delta.DifferentAt("Spec.GrantRead") || delta.DifferentAt("Spec.GrantReadACP") || delta.DifferentAt("Spec.GrantWrite") || - delta.DifferentAt("Spec.GrantWriteACP") { + delta.DifferentAt("Spec.GrantWriteACP")) { if err := rm.syncACL(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "ACLs or Grant Headers") } } - if delta.DifferentAt("Spec.CORS") { + // CORS is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.CORS") { if err := rm.syncCORS(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "CORS") } @@ -220,12 +343,14 @@ func (rm *resourceManager) customUpdateBucket( return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Encryption") } } - if delta.DifferentAt("Spec.IntelligentTiering") { + // Intelligent Tiering is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.IntelligentTiering") { if err := rm.syncIntelligentTiering(ctx, desired, latest); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "IntelligentTiering") } } - if delta.DifferentAt("Spec.Inventory") { + // Inventory is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Inventory") { if err := rm.syncInventory(ctx, desired, latest); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Inventory") } @@ -235,29 +360,33 @@ func (rm *resourceManager) customUpdateBucket( return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Lifecycle") } } - if delta.DifferentAt("Spec.Logging") { + // Logging is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Logging") { if err := rm.syncLogging(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Logging") } } - if delta.DifferentAt("Spec.Metrics") { + // Metrics is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Metrics") { if err := rm.syncMetrics(ctx, desired, latest); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Metrics") } } - if delta.DifferentAt("Spec.Notification") { + // Notification is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Notification") { if err := rm.syncNotification(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Notification") } } - if delta.DifferentAt("Spec.OwnershipControls") { + // Ownership controls are not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.OwnershipControls") { if err := rm.syncOwnershipControls(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "OwnershipControls") } } // PublicAccessBlock may need to be set in order to use Policy, so sync it - // first - if delta.DifferentAt("Spec.PublicAccessBlock") { + // first. Not supported for directory buckets. + if !isDirectoryBucket && delta.DifferentAt("Spec.PublicAccessBlock") { if err := rm.syncPublicAccessBlock(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "PublicAccessBlock") } @@ -267,26 +396,30 @@ func (rm *resourceManager) customUpdateBucket( return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Policy") } } - if delta.DifferentAt("Spec.RequestPayment") { + // Request payment is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.RequestPayment") { if err := rm.syncRequestPayment(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "RequestPayment") } } + // Tagging is supported for both general-purpose and directory buckets if delta.DifferentAt("Spec.Tagging") { if err := rm.syncTagging(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Tagging") } } - if delta.DifferentAt("Spec.Website") { + // Website is not supported for directory buckets + if !isDirectoryBucket && delta.DifferentAt("Spec.Website") { if err := rm.syncWebsite(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Website") } } + // Replication and Versioning are not supported for directory buckets // Replication requires versioning be enabled. We check that if we are // disabling versioning, that we disable replication first. If we are // enabling replication, that we enable versioning first. - if delta.DifferentAt("Spec.Replication") || delta.DifferentAt("Spec.Versioning") { + if !isDirectoryBucket && (delta.DifferentAt("Spec.Replication") || delta.DifferentAt("Spec.Versioning")) { if desired.ko.Spec.Replication == nil || desired.ko.Spec.Replication.Rules == nil { if err := rm.syncReplication(ctx, desired); err != nil { return nil, errors.Wrapf(err, ErrSyncingPutProperty, "Replication") @@ -314,48 +447,69 @@ func (rm *resourceManager) addPutFieldsToSpec( r *resource, ko *svcapitypes.Bucket, ) (err error) { - getAccelerateResponse, err := rm.sdkapi.GetBucketAccelerateConfiguration(ctx, rm.newGetBucketAcceleratePayload(r)) - if err != nil { - // This method is not supported in every region, ignore any errors if - // we attempt to describe this property in a region in which it's not - // supported. - if awsErr, ok := ackerr.AWSError(err); !ok || (awsErr.ErrorCode() != "MethodNotAllowed" && awsErr.ErrorCode() != "UnsupportedArgument") { - return err + // Check if this is a directory bucket to skip unsupported operations + isDirectoryBucket := r.ko.Spec.Name != nil && IsDirectoryBucketName(*r.ko.Spec.Name) + + // Transfer acceleration is not supported for directory buckets + if !isDirectoryBucket { + getAccelerateResponse, err := rm.sdkapi.GetBucketAccelerateConfiguration(ctx, rm.newGetBucketAcceleratePayload(r)) + if err != nil { + // This method is not supported in every region, ignore any errors if + // we attempt to describe this property in a region in which it's not + // supported. + if awsErr, ok := ackerr.AWSError(err); !ok || (awsErr.ErrorCode() != "MethodNotAllowed" && awsErr.ErrorCode() != "UnsupportedArgument") { + return err + } + } + if getAccelerateResponse == nil || getAccelerateResponse.Status == "" { + ko.Spec.Accelerate = nil + } else { + ko.Spec.Accelerate = rm.setResourceAccelerate(r, getAccelerateResponse) } - } - if getAccelerateResponse == nil || getAccelerateResponse.Status == "" { - ko.Spec.Accelerate = nil } else { - ko.Spec.Accelerate = rm.setResourceAccelerate(r, getAccelerateResponse) + ko.Spec.Accelerate = nil } - listAnalyticsResponse, err := rm.sdkapi.ListBucketAnalyticsConfigurations(ctx, rm.newListBucketAnalyticsPayload(r)) - if err != nil { - return err - } - if listAnalyticsResponse != nil && len(listAnalyticsResponse.AnalyticsConfigurationList) > 0 { - ko.Spec.Analytics = make([]*svcapitypes.AnalyticsConfiguration, len(listAnalyticsResponse.AnalyticsConfigurationList)) - for i, analyticsConfiguration := range listAnalyticsResponse.AnalyticsConfigurationList { - ko.Spec.Analytics[i] = rm.setResourceAnalyticsConfiguration(r, analyticsConfiguration) + // Analytics configurations are not supported for directory buckets + if !isDirectoryBucket { + listAnalyticsResponse, err := rm.sdkapi.ListBucketAnalyticsConfigurations(ctx, rm.newListBucketAnalyticsPayload(r)) + if err != nil { + return err + } + if listAnalyticsResponse != nil && len(listAnalyticsResponse.AnalyticsConfigurationList) > 0 { + ko.Spec.Analytics = make([]*svcapitypes.AnalyticsConfiguration, len(listAnalyticsResponse.AnalyticsConfigurationList)) + for i, analyticsConfiguration := range listAnalyticsResponse.AnalyticsConfigurationList { + ko.Spec.Analytics[i] = rm.setResourceAnalyticsConfiguration(r, analyticsConfiguration) + } + } else { + ko.Spec.Analytics = nil } } else { ko.Spec.Analytics = nil } - getACLResponse, err := rm.sdkapi.GetBucketAcl(ctx, rm.newGetBucketACLPayload(r)) - if err != nil { - return err - } - rm.setResourceACL(ko, getACLResponse) - - getCORSResponse, err := rm.sdkapi.GetBucketCors(ctx, rm.newGetBucketCORSPayload(r)) - if err != nil { - if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchCORSConfiguration" { + // ACL operations are not supported for directory buckets + if !isDirectoryBucket { + getACLResponse, err := rm.sdkapi.GetBucketAcl(ctx, rm.newGetBucketACLPayload(r)) + if err != nil { return err } + rm.setResourceACL(ko, getACLResponse) } - if getCORSResponse != nil { - ko.Spec.CORS = rm.setResourceCORS(r, getCORSResponse) + + // CORS is not supported for directory buckets + if !isDirectoryBucket { + getCORSResponse, err := rm.sdkapi.GetBucketCors(ctx, rm.newGetBucketCORSPayload(r)) + if err != nil { + if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchCORSConfiguration" { + return err + } + } + if getCORSResponse != nil { + ko.Spec.CORS = rm.setResourceCORS(r, getCORSResponse) + } else { + ko.Spec.CORS = nil + } } else { ko.Spec.CORS = nil } @@ -372,27 +526,37 @@ func (rm *resourceManager) addPutFieldsToSpec( ko.Spec.Encryption = nil } - listIntelligentTieringResponse, err := rm.sdkapi.ListBucketIntelligentTieringConfigurations(ctx, rm.newListBucketIntelligentTieringPayload(r)) - if err != nil { - return err - } - if len(listIntelligentTieringResponse.IntelligentTieringConfigurationList) > 0 { - ko.Spec.IntelligentTiering = make([]*svcapitypes.IntelligentTieringConfiguration, len(listIntelligentTieringResponse.IntelligentTieringConfigurationList)) - for i, intelligentTieringConfiguration := range listIntelligentTieringResponse.IntelligentTieringConfigurationList { - ko.Spec.IntelligentTiering[i] = rm.setResourceIntelligentTieringConfiguration(r, intelligentTieringConfiguration) + // Intelligent Tiering is not supported for directory buckets + if !isDirectoryBucket { + listIntelligentTieringResponse, err := rm.sdkapi.ListBucketIntelligentTieringConfigurations(ctx, rm.newListBucketIntelligentTieringPayload(r)) + if err != nil { + return err + } + if len(listIntelligentTieringResponse.IntelligentTieringConfigurationList) > 0 { + ko.Spec.IntelligentTiering = make([]*svcapitypes.IntelligentTieringConfiguration, len(listIntelligentTieringResponse.IntelligentTieringConfigurationList)) + for i, intelligentTieringConfiguration := range listIntelligentTieringResponse.IntelligentTieringConfigurationList { + ko.Spec.IntelligentTiering[i] = rm.setResourceIntelligentTieringConfiguration(r, intelligentTieringConfiguration) + } + } else { + ko.Spec.IntelligentTiering = nil } } else { ko.Spec.IntelligentTiering = nil } - listInventoryResponse, err := rm.sdkapi.ListBucketInventoryConfigurations(ctx, rm.newListBucketInventoryPayload(r)) - if err != nil { - return err - } + // Inventory is not supported for directory buckets + if !isDirectoryBucket { + listInventoryResponse, err := rm.sdkapi.ListBucketInventoryConfigurations(ctx, rm.newListBucketInventoryPayload(r)) + if err != nil { + return err + } - ko.Spec.Inventory = make([]*svcapitypes.InventoryConfiguration, len(listInventoryResponse.InventoryConfigurationList)) - for i, inventoryConfiguration := range listInventoryResponse.InventoryConfigurationList { - ko.Spec.Inventory[i] = rm.setResourceInventoryConfiguration(r, inventoryConfiguration) + ko.Spec.Inventory = make([]*svcapitypes.InventoryConfiguration, len(listInventoryResponse.InventoryConfigurationList)) + for i, inventoryConfiguration := range listInventoryResponse.InventoryConfigurationList { + ko.Spec.Inventory[i] = rm.setResourceInventoryConfiguration(r, inventoryConfiguration) + } + } else { + ko.Spec.Inventory = nil } getLifecycleResponse, err := rm.sdkapi.GetBucketLifecycleConfiguration(ctx, rm.newGetBucketLifecyclePayload(r)) @@ -407,50 +571,70 @@ func (rm *resourceManager) addPutFieldsToSpec( ko.Spec.Lifecycle = nil } - getLoggingResponse, err := rm.sdkapi.GetBucketLogging(ctx, rm.newGetBucketLoggingPayload(r)) - if err != nil { - return err - } - if getLoggingResponse.LoggingEnabled != nil { - ko.Spec.Logging = rm.setResourceLogging(r, getLoggingResponse) + // Logging is not supported for directory buckets + if !isDirectoryBucket { + getLoggingResponse, err := rm.sdkapi.GetBucketLogging(ctx, rm.newGetBucketLoggingPayload(r)) + if err != nil { + return err + } + if getLoggingResponse.LoggingEnabled != nil { + ko.Spec.Logging = rm.setResourceLogging(r, getLoggingResponse) + } else { + ko.Spec.Logging = nil + } } else { ko.Spec.Logging = nil } - listMetricsResponse, err := rm.sdkapi.ListBucketMetricsConfigurations(ctx, rm.newListBucketMetricsPayload(r)) - if err != nil { - return err - } - if len(listMetricsResponse.MetricsConfigurationList) > 0 { - ko.Spec.Metrics = make([]*svcapitypes.MetricsConfiguration, len(listMetricsResponse.MetricsConfigurationList)) - for i, metricsConfiguration := range listMetricsResponse.MetricsConfigurationList { - ko.Spec.Metrics[i] = rm.setResourceMetricsConfiguration(r, &metricsConfiguration) + // Metrics is not supported for directory buckets + if !isDirectoryBucket { + listMetricsResponse, err := rm.sdkapi.ListBucketMetricsConfigurations(ctx, rm.newListBucketMetricsPayload(r)) + if err != nil { + return err + } + if len(listMetricsResponse.MetricsConfigurationList) > 0 { + ko.Spec.Metrics = make([]*svcapitypes.MetricsConfiguration, len(listMetricsResponse.MetricsConfigurationList)) + for i, metricsConfiguration := range listMetricsResponse.MetricsConfigurationList { + ko.Spec.Metrics[i] = rm.setResourceMetricsConfiguration(r, &metricsConfiguration) + } + } else { + ko.Spec.Metrics = nil } } else { ko.Spec.Metrics = nil } - getNotificationResponse, err := rm.sdkapi.GetBucketNotificationConfiguration(ctx, rm.newGetBucketNotificationPayload(r)) - if err != nil { - return err - } - if getNotificationResponse.LambdaFunctionConfigurations != nil || - getNotificationResponse.QueueConfigurations != nil || - getNotificationResponse.TopicConfigurations != nil { + // Notification is not supported for directory buckets + if !isDirectoryBucket { + getNotificationResponse, err := rm.sdkapi.GetBucketNotificationConfiguration(ctx, rm.newGetBucketNotificationPayload(r)) + if err != nil { + return err + } + if getNotificationResponse.LambdaFunctionConfigurations != nil || + getNotificationResponse.QueueConfigurations != nil || + getNotificationResponse.TopicConfigurations != nil { - ko.Spec.Notification = rm.setResourceNotification(r, getNotificationResponse) + ko.Spec.Notification = rm.setResourceNotification(r, getNotificationResponse) + } else { + ko.Spec.Notification = nil + } } else { ko.Spec.Notification = nil } - getOwnershipControlsResponse, err := rm.sdkapi.GetBucketOwnershipControls(ctx, rm.newGetBucketOwnershipControlsPayload(r)) - if err != nil { - if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "OwnershipControlsNotFoundError" { - return err + // Ownership controls are not supported for directory buckets (they use bucket owner enforced by default) + if !isDirectoryBucket { + getOwnershipControlsResponse, err := rm.sdkapi.GetBucketOwnershipControls(ctx, rm.newGetBucketOwnershipControlsPayload(r)) + if err != nil { + if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "OwnershipControlsNotFoundError" { + return err + } + } + if getOwnershipControlsResponse != nil { + ko.Spec.OwnershipControls = rm.setResourceOwnershipControls(r, getOwnershipControlsResponse) + } else { + ko.Spec.OwnershipControls = nil } - } - if getOwnershipControlsResponse != nil { - ko.Spec.OwnershipControls = rm.setResourceOwnershipControls(r, getOwnershipControlsResponse) } else { ko.Spec.OwnershipControls = nil } @@ -467,70 +651,104 @@ func (rm *resourceManager) addPutFieldsToSpec( ko.Spec.Policy = nil } - getPublicAccessBlockResponse, err := rm.sdkapi.GetPublicAccessBlock(ctx, rm.newGetPublicAccessBlockPayload(r)) - if err != nil { - if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchPublicAccessBlockConfiguration" { - return err + // Public access block is not supported for directory buckets + if !isDirectoryBucket { + getPublicAccessBlockResponse, err := rm.sdkapi.GetPublicAccessBlock(ctx, rm.newGetPublicAccessBlockPayload(r)) + if err != nil { + if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchPublicAccessBlockConfiguration" { + return err + } + } + if getPublicAccessBlockResponse != nil { + ko.Spec.PublicAccessBlock = rm.setResourcePublicAccessBlock(r, getPublicAccessBlockResponse) + } else { + ko.Spec.PublicAccessBlock = nil } - } - if getPublicAccessBlockResponse != nil { - ko.Spec.PublicAccessBlock = rm.setResourcePublicAccessBlock(r, getPublicAccessBlockResponse) } else { ko.Spec.PublicAccessBlock = nil } - getReplicationResponse, err := rm.sdkapi.GetBucketReplication(ctx, rm.newGetBucketReplicationPayload(r)) - if err != nil { - if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "ReplicationConfigurationNotFoundError" { - return err + // Replication is not supported for directory buckets + if !isDirectoryBucket { + getReplicationResponse, err := rm.sdkapi.GetBucketReplication(ctx, rm.newGetBucketReplicationPayload(r)) + if err != nil { + if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "ReplicationConfigurationNotFoundError" { + return err + } + } + if getReplicationResponse != nil { + ko.Spec.Replication = rm.setResourceReplication(r, getReplicationResponse) + } else { + ko.Spec.Replication = nil } - } - if getReplicationResponse != nil { - ko.Spec.Replication = rm.setResourceReplication(r, getReplicationResponse) } else { ko.Spec.Replication = nil } - getRequestPaymentResponse, err := rm.sdkapi.GetBucketRequestPayment(ctx, rm.newGetBucketRequestPaymentPayload(r)) - if err != nil { - return nil - } - if getRequestPaymentResponse.Payer != "" { - ko.Spec.RequestPayment = rm.setResourceRequestPayment(r, getRequestPaymentResponse) + // Request payment is not supported for directory buckets + if !isDirectoryBucket { + getRequestPaymentResponse, err := rm.sdkapi.GetBucketRequestPayment(ctx, rm.newGetBucketRequestPaymentPayload(r)) + if err != nil { + return err + } + if getRequestPaymentResponse.Payer != "" { + ko.Spec.RequestPayment = rm.setResourceRequestPayment(r, getRequestPaymentResponse) + } else { + ko.Spec.RequestPayment = nil + } } else { ko.Spec.RequestPayment = nil } - getTaggingResponse, err := rm.sdkapi.GetBucketTagging(ctx, rm.newGetBucketTaggingPayload(r)) - if err != nil { - if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchTagSet" { - return err + // Handle tagging for both general-purpose and directory buckets + if !isDirectoryBucket { + getTaggingResponse, err := rm.sdkapi.GetBucketTagging(ctx, rm.newGetBucketTaggingPayload(r)) + if err != nil { + if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchTagSet" { + return err + } + } + if getTaggingResponse != nil && getTaggingResponse.TagSet != nil { + ko.Spec.Tagging = rm.setResourceTagging(r, getTaggingResponse) + } else { + ko.Spec.Tagging = nil } - } - if getTaggingResponse != nil && getTaggingResponse.TagSet != nil { - ko.Spec.Tagging = rm.setResourceTagging(r, getTaggingResponse) } else { - ko.Spec.Tagging = nil + // Directory buckets use S3 Control API for tagging + err := rm.getDirectoryBucketTagging(ctx, r, ko) + if err != nil { + return err + } } - getVersioningResponse, err := rm.sdkapi.GetBucketVersioning(ctx, rm.newGetBucketVersioningPayload(r)) - if err != nil { - return err - } - if getVersioningResponse.Status != "" { - ko.Spec.Versioning = rm.setResourceVersioning(r, getVersioningResponse) + // Versioning is not supported for directory buckets + if !isDirectoryBucket { + getVersioningResponse, err := rm.sdkapi.GetBucketVersioning(ctx, rm.newGetBucketVersioningPayload(r)) + if err != nil { + return err + } + if getVersioningResponse.Status != "" { + ko.Spec.Versioning = rm.setResourceVersioning(r, getVersioningResponse) + } else { + ko.Spec.Versioning = nil + } } else { ko.Spec.Versioning = nil } - getWebsiteResponse, err := rm.sdkapi.GetBucketWebsite(ctx, rm.newGetBucketWebsitePayload(r)) - if err != nil { - if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchWebsiteConfiguration" { - return err + // Website hosting is not supported for directory buckets + if !isDirectoryBucket { + getWebsiteResponse, err := rm.sdkapi.GetBucketWebsite(ctx, rm.newGetBucketWebsitePayload(r)) + if err != nil { + if awsErr, ok := ackerr.AWSError(err); !ok || awsErr.ErrorCode() != "NoSuchWebsiteConfiguration" { + return err + } + } + if getWebsiteResponse != nil { + ko.Spec.Website = rm.setResourceWebsite(r, getWebsiteResponse) + } else { + ko.Spec.Website = nil } - } - if getWebsiteResponse != nil { - ko.Spec.Website = rm.setResourceWebsite(r, getWebsiteResponse) } else { ko.Spec.Website = nil } @@ -1527,6 +1745,12 @@ func (rm *resourceManager) putTagging( rlog := ackrtlog.FromContext(ctx) exit := rlog.Trace("rm.putTagging") defer exit(err) + + // Directory buckets use S3 Control API for tagging + if r.ko.Spec.Name != nil && IsDirectoryBucketName(*r.ko.Spec.Name) { + return rm.putDirectoryBucketTagging(ctx, r) + } + input := rm.newPutBucketTaggingPayload(r) _, err = rm.sdkapi.PutBucketTagging(ctx, input) @@ -1538,6 +1762,123 @@ func (rm *resourceManager) putTagging( return nil } +// putDirectoryBucketTagging applies tags to a directory bucket using the S3 Control API +func (rm *resourceManager) putDirectoryBucketTagging( + ctx context.Context, + r *resource, +) (err error) { + rlog := ackrtlog.FromContext(ctx) + + if r.ko.Spec.Tagging == nil || r.ko.Spec.Tagging.TagSet == nil { + rlog.Info("No tags to apply to directory bucket") + return nil + } + + s3controlClient := s3control.NewFromConfig(rm.clientcfg) + + // Convert tags to S3 Control format + var tags []s3controltypes.Tag + for _, tag := range r.ko.Spec.Tagging.TagSet { + if tag.Key != nil && tag.Value != nil { + tags = append(tags, s3controltypes.Tag{ + Key: tag.Key, + Value: tag.Value, + }) + } + } + + if len(tags) == 0 { + rlog.Info("No valid tags to apply to directory bucket") + return nil + } + + // Build bucket ARN for directory bucket + bucketName := *r.ko.Spec.Name + bucketARN := fmt.Sprintf("arn:aws:s3express:%s:%s:bucket/%s", + string(rm.awsRegion), + string(rm.awsAccountID), + bucketName) + + rlog.Info("Applying tags to directory bucket using S3 Control API", + "bucketARN", bucketARN, + "tagCount", len(tags)) + + input := &s3control.TagResourceInput{ + ResourceArn: aws.String(bucketARN), + AccountId: aws.String(string(rm.awsAccountID)), + Tags: tags, + } + + _, err = s3controlClient.TagResource(ctx, input) + rm.metrics.RecordAPICall("UPDATE", "TagResource", err) + if err != nil { + return errors.Wrap(err, "failed to tag directory bucket") + } + + rlog.Info("Successfully applied tags to directory bucket") + return nil +} + +// getDirectoryBucketTagging retrieves tags from a directory bucket using the S3 Control API +func (rm *resourceManager) getDirectoryBucketTagging( + ctx context.Context, + r *resource, + ko *svcapitypes.Bucket, +) error { + rlog := ackrtlog.FromContext(ctx) + + s3controlClient := s3control.NewFromConfig(rm.clientcfg) + + bucketName := *r.ko.Spec.Name + bucketARN := fmt.Sprintf("arn:aws:s3express:%s:%s:bucket/%s", + string(rm.awsRegion), + string(rm.awsAccountID), + bucketName) + + rlog.Info("Retrieving tags from directory bucket using S3 Control API", + "bucketARN", bucketARN) + + input := &s3control.ListTagsForResourceInput{ + ResourceArn: aws.String(bucketARN), + AccountId: aws.String(string(rm.awsAccountID)), + } + + resp, err := s3controlClient.ListTagsForResource(ctx, input) + rm.metrics.RecordAPICall("READ_ONE", "ListTagsForResource", err) + rlog.Debug("", + "bucketARN", bucketARN) + if err != nil { + // Handle no tags case + if awsErr, ok := ackerr.AWSError(err); ok && awsErr.ErrorCode() == "NoSuchTagSet" { + ko.Spec.Tagging = nil + return nil + } + return errors.Wrap(err, "failed to get directory bucket tags") + } + + if resp == nil || len(resp.Tags) == 0 { + ko.Spec.Tagging = nil + return nil + } + + tagging := &svcapitypes.Tagging{ + TagSet: make([]*svcapitypes.Tag, 0, len(resp.Tags)), + } + + for _, tag := range resp.Tags { + if tag.Key != nil && tag.Value != nil { + tagging.TagSet = append(tagging.TagSet, &svcapitypes.Tag{ + Key: tag.Key, + Value: tag.Value, + }) + } + } + + ko.Spec.Tagging = tagging + rlog.Info("Successfully retrieved tags from directory bucket", "tagCount", len(resp.Tags)) + return nil +} + func (rm *resourceManager) deleteTagging( ctx context.Context, r *resource, @@ -1545,6 +1886,12 @@ func (rm *resourceManager) deleteTagging( rlog := ackrtlog.FromContext(ctx) exit := rlog.Trace("rm.deleteTagging") defer exit(err) + + // Directory buckets use S3 Control API for tag deletion + if r.ko.Spec.Name != nil && IsDirectoryBucketName(*r.ko.Spec.Name) { + return rm.deleteDirectoryBucketTagging(ctx, r) + } + input := rm.newDeleteBucketTaggingPayload(r) _, err = rm.sdkapi.DeleteBucketTagging(ctx, input) @@ -1556,6 +1903,73 @@ func (rm *resourceManager) deleteTagging( return nil } +// deleteDirectoryBucketTagging removes all tags from a directory bucket using the S3 Control API +func (rm *resourceManager) deleteDirectoryBucketTagging( + ctx context.Context, + r *resource, +) error { + rlog := ackrtlog.FromContext(ctx) + + s3controlClient := s3control.NewFromConfig(rm.clientcfg) + + bucketName := *r.ko.Spec.Name + bucketARN := fmt.Sprintf("arn:aws:s3express:%s:%s:bucket/%s", + string(rm.awsRegion), + string(rm.awsAccountID), + bucketName) + + getInput := &s3control.ListTagsForResourceInput{ + ResourceArn: aws.String(bucketARN), + AccountId: aws.String(string(rm.awsAccountID)), + } + + resp, err := s3controlClient.ListTagsForResource(ctx, getInput) + if err != nil { + // Handle no tags case + if awsErr, ok := ackerr.AWSError(err); ok && awsErr.ErrorCode() == "NoSuchTagSet" { + rlog.Info("No tags to delete from directory bucket") + return nil + } + return errors.Wrap(err, "failed to get directory bucket tags for deletion") + } + + if resp == nil || len(resp.Tags) == 0 { + rlog.Info("No tags to delete from directory bucket") + return nil + } + + tagKeys := make([]string, 0, len(resp.Tags)) + for _, tag := range resp.Tags { + if tag.Key != nil { + tagKeys = append(tagKeys, *tag.Key) + } + } + + if len(tagKeys) == 0 { + rlog.Info("No valid tag keys to delete from directory bucket") + return nil + } + + rlog.Info("Deleting tags from directory bucket using S3 Control API", + "bucketARN", bucketARN, + "tagCount", len(tagKeys)) + + deleteInput := &s3control.UntagResourceInput{ + ResourceArn: aws.String(bucketARN), + AccountId: aws.String(string(rm.awsAccountID)), + TagKeys: tagKeys, + } + + _, err = s3controlClient.UntagResource(ctx, deleteInput) + rm.metrics.RecordAPICall("DELETE", "UntagResource", err) + if err != nil { + return errors.Wrap(err, "failed to delete directory bucket tags") + } + + rlog.Info("Successfully deleted tags from directory bucket") + return nil +} + func (rm *resourceManager) syncTagging( ctx context.Context, r *resource, @@ -1692,3 +2106,88 @@ func (rm *resourceManager) syncWebsite( } //endregion website + +// IsDirectoryBucketName checks if a bucket name follows the directory bucket naming pattern. +// Directory buckets must end with "--x-s3" suffix and follow the format: +// bucket-base-name--zone-id--x-s3 +func IsDirectoryBucketName(bucketName string) bool { + return strings.HasSuffix(bucketName, "--x-s3") +} + +// customFindBucket is a custom implementation of sdkFind that handles both +// general-purpose buckets and directory buckets by calling the appropriate +// List operation based on the bucket name pattern. +func (rm *resourceManager) customFindBucket( + ctx context.Context, + r *resource, +) (latest *resource, err error) { + rlog := ackrtlog.FromContext(ctx) + exit := rlog.Trace("rm.customFindBucket") + defer func() { + exit(err) + }() + + // Check if we have a bucket name to search for + if r.ko.Spec.Name == nil { + return nil, ackerr.NotFound + } + + bucketName := *r.ko.Spec.Name + ko := r.ko.DeepCopy() + found := false + + if IsDirectoryBucketName(bucketName) { + input := &svcsdk.ListDirectoryBucketsInput{} + var resp *svcsdk.ListDirectoryBucketsOutput + resp, err = rm.sdkapi.ListDirectoryBuckets(ctx, input) + rm.metrics.RecordAPICall("READ_MANY", "ListDirectoryBuckets", err) + if err != nil { + return nil, err + } + + // Search for the bucket in the response + for _, bucket := range resp.Buckets { + if bucket.Name != nil && *bucket.Name == bucketName { + ko.Spec.Name = bucket.Name + found = true + break + } + } + } else { + // Use ListBuckets for general-purpose buckets + input := &svcsdk.ListBucketsInput{} + var resp *svcsdk.ListBucketsOutput + resp, err = rm.sdkapi.ListBuckets(ctx, input) + rm.metrics.RecordAPICall("READ_MANY", "ListBuckets", err) + if err != nil { + var awsErr smithy.APIError + if errors.As(err, &awsErr) && awsErr.ErrorCode() == "NoSuchBucket" { + return nil, ackerr.NotFound + } + return nil, err + } + + // Search for the bucket in the response + for _, bucket := range resp.Buckets { + if bucket.Name != nil && *bucket.Name == bucketName { + ko.Spec.Name = bucket.Name + found = true + break + } + } + } + + if !found { + return nil, ackerr.NotFound + } + + rm.setStatusDefaults(ko) + if err := rm.addPutFieldsToSpec(ctx, r, ko); err != nil { + return nil, err + } + + // Set bucket ARN in the output + arn := bucketARN(bucketName) + ko.Status.ACKResourceMetadata.ARN = (*ackv1alpha1.AWSResourceName)(&arn) + return &resource{ko}, nil +} diff --git a/pkg/resource/bucket/hook_test.go b/pkg/resource/bucket/hook_test.go new file mode 100644 index 0000000..2d4ad36 --- /dev/null +++ b/pkg/resource/bucket/hook_test.go @@ -0,0 +1,31 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// +// Licensed under the Apache License, Version 2.0 (the "License"). You may +// not use this file except in compliance with the License. A copy of the +// License is located at +// +// http://aws.amazon.com/apache2.0/ +// +// or in the "license" file accompanying this file. This file 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 bucket_test + +import ( + "testing" + + bucket "github.com/aws-controllers-k8s/s3-controller/pkg/resource/bucket" + "github.com/stretchr/testify/assert" +) + +func Test_IsDirectoryBucketName(t *testing.T) { + assert := assert.New(t) + + assert.True(bucket.IsDirectoryBucketName("my-bucket--usw2-az5--x-s3")) + assert.True(bucket.IsDirectoryBucketName("my-bucket--use1-az2--x-s3")) + + assert.False(bucket.IsDirectoryBucketName("my-regular-bucket")) + assert.False(bucket.IsDirectoryBucketName("bucket-with--use1-az2-zone")) +} diff --git a/pkg/resource/bucket/sdk.go b/pkg/resource/bucket/sdk.go index 3028e3f..489a4b3 100644 --- a/pkg/resource/bucket/sdk.go +++ b/pkg/resource/bucket/sdk.go @@ -57,85 +57,8 @@ var ( func (rm *resourceManager) sdkFind( ctx context.Context, r *resource, -) (latest *resource, err error) { - rlog := ackrtlog.FromContext(ctx) - exit := rlog.Trace("rm.sdkFind") - defer func() { - exit(err) - }() - // If any required fields in the input shape are missing, AWS resource is - // not created yet. Return NotFound here to indicate to callers that the - // resource isn't yet created. - if rm.requiredFieldsMissingFromReadManyInput(r) { - return nil, ackerr.NotFound - } - - input, err := rm.newListRequestPayload(r) - if err != nil { - return nil, err - } - var resp *svcsdk.ListBucketsOutput - resp, err = rm.sdkapi.ListBuckets(ctx, input) - rm.metrics.RecordAPICall("READ_MANY", "ListBuckets", err) - if err != nil { - var awsErr smithy.APIError - if errors.As(err, &awsErr) && awsErr.ErrorCode() == "NoSuchBucket" { - return nil, ackerr.NotFound - } - return nil, err - } - - // Merge in the information we read from the API call above to the copy of - // the original Kubernetes object we passed to the function - ko := r.ko.DeepCopy() - - found := false - for _, elem := range resp.Buckets { - if elem.Name != nil { - if ko.Spec.Name != nil { - if *elem.Name != *ko.Spec.Name { - continue - } - } - ko.Spec.Name = elem.Name - } else { - ko.Spec.Name = nil - } - found = true - break - } - if !found { - return nil, ackerr.NotFound - } - - rm.setStatusDefaults(ko) - if err := rm.addPutFieldsToSpec(ctx, r, ko); err != nil { - return nil, err - } - - // Set bucket ARN in the output - bucketARN := ackv1alpha1.AWSResourceName(bucketARN(*ko.Spec.Name)) - ko.Status.ACKResourceMetadata.ARN = &bucketARN - return &resource{ko}, nil -} - -// requiredFieldsMissingFromReadManyInput returns true if there are any fields -// for the ReadMany Input shape that are required but not present in the -// resource's Spec or Status -func (rm *resourceManager) requiredFieldsMissingFromReadManyInput( - r *resource, -) bool { - return false -} - -// newListRequestPayload returns SDK-specific struct for the HTTP request -// payload of the List API call for the resource -func (rm *resourceManager) newListRequestPayload( - r *resource, -) (*svcsdk.ListBucketsInput, error) { - res := &svcsdk.ListBucketsInput{} - - return res, nil +) (*resource, error) { + return rm.customFindBucket(ctx, r) } // sdkCreate creates the supplied resource in the backend AWS service API and @@ -154,8 +77,17 @@ func (rm *resourceManager) sdkCreate( if err != nil { return nil, err } + // Validate directory bucket configuration + if err := validateDirectoryBucketSpec(desired.ko); err != nil { + return nil, err + } + // Set default region for general-purpose buckets only (not directory buckets) + // Directory buckets use Location/Bucket fields instead of LocationConstraint + isDirectoryBucket := input.CreateBucketConfiguration != nil && + input.CreateBucketConfiguration.Location != nil && + input.CreateBucketConfiguration.Bucket != nil - if rm.awsRegion != "us-east-1" { + if rm.awsRegion != "us-east-1" && !isDirectoryBucket { // Set default region if not specified if input.CreateBucketConfiguration == nil || input.CreateBucketConfiguration.LocationConstraint == "" { @@ -205,6 +137,26 @@ func (rm *resourceManager) newCreateRequestPayload( } if r.ko.Spec.CreateBucketConfiguration != nil { f2 := &svcsdktypes.CreateBucketConfiguration{} + if r.ko.Spec.CreateBucketConfiguration.Bucket != nil { + f2f0 := &svcsdktypes.BucketInfo{} + if r.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy != nil { + f2f0.DataRedundancy = svcsdktypes.DataRedundancy(*r.ko.Spec.CreateBucketConfiguration.Bucket.DataRedundancy) + } + if r.ko.Spec.CreateBucketConfiguration.Bucket.Type != nil { + f2f0.Type = svcsdktypes.BucketType(*r.ko.Spec.CreateBucketConfiguration.Bucket.Type) + } + f2.Bucket = f2f0 + } + if r.ko.Spec.CreateBucketConfiguration.Location != nil { + f2f1 := &svcsdktypes.LocationInfo{} + if r.ko.Spec.CreateBucketConfiguration.Location.Name != nil { + f2f1.Name = r.ko.Spec.CreateBucketConfiguration.Location.Name + } + if r.ko.Spec.CreateBucketConfiguration.Location.Type != nil { + f2f1.Type = svcsdktypes.LocationType(*r.ko.Spec.CreateBucketConfiguration.Location.Type) + } + f2.Location = f2f1 + } if r.ko.Spec.CreateBucketConfiguration.LocationConstraint != nil { f2.LocationConstraint = svcsdktypes.BucketLocationConstraint(*r.ko.Spec.CreateBucketConfiguration.LocationConstraint) } diff --git a/templates/hooks/bucket/sdk_create_post_build_request.go.tpl b/templates/hooks/bucket/sdk_create_post_build_request.go.tpl index 986d3d4..4f21ade 100644 --- a/templates/hooks/bucket/sdk_create_post_build_request.go.tpl +++ b/templates/hooks/bucket/sdk_create_post_build_request.go.tpl @@ -1,5 +1,14 @@ + // Validate directory bucket configuration + if err := validateDirectoryBucketSpec(desired.ko); err != nil { + return nil, err + } + // Set default region for general-purpose buckets only (not directory buckets) + // Directory buckets use Location/Bucket fields instead of LocationConstraint + isDirectoryBucket := input.CreateBucketConfiguration != nil && + input.CreateBucketConfiguration.Location != nil && + input.CreateBucketConfiguration.Bucket != nil - if rm.awsRegion != "us-east-1" { + if rm.awsRegion != "us-east-1" && !isDirectoryBucket { // Set default region if not specified if input.CreateBucketConfiguration == nil || input.CreateBucketConfiguration.LocationConstraint == "" {