diff --git a/ecr-login/Gopkg.lock b/ecr-login/Gopkg.lock index 81ef3efa..56cad37c 100644 --- a/ecr-login/Gopkg.lock +++ b/ecr-login/Gopkg.lock @@ -2,7 +2,7 @@ [[projects]] - digest = "1:344cbac3d1ebe41c801a4bd7c05a3076dab4007effff9da203e081fb224660ad" + digest = "1:8bd893416d43197b487d4c42c8ab003653a81095e0e1692f39eb9103536a10eb" name = "github.com/aws/aws-sdk-go" packages = [ "aws", @@ -14,6 +14,7 @@ "aws/credentials", "aws/credentials/ec2rolecreds", "aws/credentials/endpointcreds", + "aws/credentials/processcreds", "aws/credentials/stscreds", "aws/csm", "aws/defaults", @@ -39,8 +40,8 @@ "service/sts", ] pruneopts = "UT" - revision = "34ab03ee1a2b90b3baf97ff666397c8fb9b8714b" - version = "v1.15.64" + revision = "81f3829f5a9d041041bdf56e55926691309d7699" + version = "v1.16.26" [[projects]] digest = "1:ffe9824d294da03b391f44e1ae8281281b4afc1bdaa9588c9097785e3af10cec" @@ -67,11 +68,11 @@ version = "v1.1.1" [[projects]] - digest = "1:e22af8c7518e1eab6f2eab2b7d7558927f816262586cd6ed9f349c97a6c285c4" + digest = "1:bb81097a5b62634f3e9fec1014657855610c82d19b9a40c17612e32651e35dca" name = "github.com/jmespath/go-jmespath" packages = ["."] pruneopts = "UT" - revision = "0b12d6b5" + revision = "c2b33e84" [[projects]] digest = "1:0a69a1c0db3591fcefb47f115b224592c8dfa4368b7ba9fae509d5e16cdc95c8" diff --git a/ecr-login/api/mocks/api_mocks.go b/ecr-login/api/mocks/api_mocks.go index 3d95f093..6a8384f8 100644 --- a/ecr-login/api/mocks/api_mocks.go +++ b/ecr-login/api/mocks/api_mocks.go @@ -11,1095 +11,1061 @@ // express or implied. See the License for the specific language governing // permissions and limitations under the License. -// Code generated by MockGen. DO NOT EDIT. +// Automatically generated by MockGen. DO NOT EDIT! // Source: github.com/aws/aws-sdk-go/service/ecr/ecriface (interfaces: ECRAPI) -// Package mock_ecriface is a generated GoMock package. package mock_ecriface import ( - reflect "reflect" + context "context" - aws "github.com/aws/aws-sdk-go/aws" request "github.com/aws/aws-sdk-go/aws/request" ecr "github.com/aws/aws-sdk-go/service/ecr" gomock "github.com/golang/mock/gomock" ) -// MockECRAPI is a mock of ECRAPI interface +// Mock of ECRAPI interface type MockECRAPI struct { ctrl *gomock.Controller - recorder *MockECRAPIMockRecorder + recorder *_MockECRAPIRecorder } -// MockECRAPIMockRecorder is the mock recorder for MockECRAPI -type MockECRAPIMockRecorder struct { +// Recorder for MockECRAPI (not exported) +type _MockECRAPIRecorder struct { mock *MockECRAPI } -// NewMockECRAPI creates a new mock instance func NewMockECRAPI(ctrl *gomock.Controller) *MockECRAPI { mock := &MockECRAPI{ctrl: ctrl} - mock.recorder = &MockECRAPIMockRecorder{mock} + mock.recorder = &_MockECRAPIRecorder{mock} return mock } -// EXPECT returns an object that allows the caller to indicate expected use -func (m *MockECRAPI) EXPECT() *MockECRAPIMockRecorder { - return m.recorder +func (_m *MockECRAPI) EXPECT() *_MockECRAPIRecorder { + return _m.recorder } -// BatchCheckLayerAvailability mocks base method -func (m *MockECRAPI) BatchCheckLayerAvailability(arg0 *ecr.BatchCheckLayerAvailabilityInput) (*ecr.BatchCheckLayerAvailabilityOutput, error) { - ret := m.ctrl.Call(m, "BatchCheckLayerAvailability", arg0) +func (_m *MockECRAPI) BatchCheckLayerAvailability(_param0 *ecr.BatchCheckLayerAvailabilityInput) (*ecr.BatchCheckLayerAvailabilityOutput, error) { + ret := _m.ctrl.Call(_m, "BatchCheckLayerAvailability", _param0) ret0, _ := ret[0].(*ecr.BatchCheckLayerAvailabilityOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// BatchCheckLayerAvailability indicates an expected call of BatchCheckLayerAvailability -func (mr *MockECRAPIMockRecorder) BatchCheckLayerAvailability(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchCheckLayerAvailability", reflect.TypeOf((*MockECRAPI)(nil).BatchCheckLayerAvailability), arg0) +func (_mr *_MockECRAPIRecorder) BatchCheckLayerAvailability(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchCheckLayerAvailability", arg0) } -// BatchCheckLayerAvailabilityRequest mocks base method -func (m *MockECRAPI) BatchCheckLayerAvailabilityRequest(arg0 *ecr.BatchCheckLayerAvailabilityInput) (*request.Request, *ecr.BatchCheckLayerAvailabilityOutput) { - ret := m.ctrl.Call(m, "BatchCheckLayerAvailabilityRequest", arg0) +func (_m *MockECRAPI) BatchCheckLayerAvailabilityRequest(_param0 *ecr.BatchCheckLayerAvailabilityInput) (*request.Request, *ecr.BatchCheckLayerAvailabilityOutput) { + ret := _m.ctrl.Call(_m, "BatchCheckLayerAvailabilityRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.BatchCheckLayerAvailabilityOutput) return ret0, ret1 } -// BatchCheckLayerAvailabilityRequest indicates an expected call of BatchCheckLayerAvailabilityRequest -func (mr *MockECRAPIMockRecorder) BatchCheckLayerAvailabilityRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchCheckLayerAvailabilityRequest", reflect.TypeOf((*MockECRAPI)(nil).BatchCheckLayerAvailabilityRequest), arg0) +func (_mr *_MockECRAPIRecorder) BatchCheckLayerAvailabilityRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchCheckLayerAvailabilityRequest", arg0) } -// BatchCheckLayerAvailabilityWithContext mocks base method -func (m *MockECRAPI) BatchCheckLayerAvailabilityWithContext(arg0 aws.Context, arg1 *ecr.BatchCheckLayerAvailabilityInput, arg2 ...request.Option) (*ecr.BatchCheckLayerAvailabilityOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) BatchCheckLayerAvailabilityWithContext(_param0 context.Context, _param1 *ecr.BatchCheckLayerAvailabilityInput, _param2 ...request.Option) (*ecr.BatchCheckLayerAvailabilityOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "BatchCheckLayerAvailabilityWithContext", varargs...) + ret := _m.ctrl.Call(_m, "BatchCheckLayerAvailabilityWithContext", _s...) ret0, _ := ret[0].(*ecr.BatchCheckLayerAvailabilityOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// BatchCheckLayerAvailabilityWithContext indicates an expected call of BatchCheckLayerAvailabilityWithContext -func (mr *MockECRAPIMockRecorder) BatchCheckLayerAvailabilityWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchCheckLayerAvailabilityWithContext", reflect.TypeOf((*MockECRAPI)(nil).BatchCheckLayerAvailabilityWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) BatchCheckLayerAvailabilityWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchCheckLayerAvailabilityWithContext", _s...) } -// BatchDeleteImage mocks base method -func (m *MockECRAPI) BatchDeleteImage(arg0 *ecr.BatchDeleteImageInput) (*ecr.BatchDeleteImageOutput, error) { - ret := m.ctrl.Call(m, "BatchDeleteImage", arg0) +func (_m *MockECRAPI) BatchDeleteImage(_param0 *ecr.BatchDeleteImageInput) (*ecr.BatchDeleteImageOutput, error) { + ret := _m.ctrl.Call(_m, "BatchDeleteImage", _param0) ret0, _ := ret[0].(*ecr.BatchDeleteImageOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// BatchDeleteImage indicates an expected call of BatchDeleteImage -func (mr *MockECRAPIMockRecorder) BatchDeleteImage(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchDeleteImage", reflect.TypeOf((*MockECRAPI)(nil).BatchDeleteImage), arg0) +func (_mr *_MockECRAPIRecorder) BatchDeleteImage(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchDeleteImage", arg0) } -// BatchDeleteImageRequest mocks base method -func (m *MockECRAPI) BatchDeleteImageRequest(arg0 *ecr.BatchDeleteImageInput) (*request.Request, *ecr.BatchDeleteImageOutput) { - ret := m.ctrl.Call(m, "BatchDeleteImageRequest", arg0) +func (_m *MockECRAPI) BatchDeleteImageRequest(_param0 *ecr.BatchDeleteImageInput) (*request.Request, *ecr.BatchDeleteImageOutput) { + ret := _m.ctrl.Call(_m, "BatchDeleteImageRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.BatchDeleteImageOutput) return ret0, ret1 } -// BatchDeleteImageRequest indicates an expected call of BatchDeleteImageRequest -func (mr *MockECRAPIMockRecorder) BatchDeleteImageRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchDeleteImageRequest", reflect.TypeOf((*MockECRAPI)(nil).BatchDeleteImageRequest), arg0) +func (_mr *_MockECRAPIRecorder) BatchDeleteImageRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchDeleteImageRequest", arg0) } -// BatchDeleteImageWithContext mocks base method -func (m *MockECRAPI) BatchDeleteImageWithContext(arg0 aws.Context, arg1 *ecr.BatchDeleteImageInput, arg2 ...request.Option) (*ecr.BatchDeleteImageOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) BatchDeleteImageWithContext(_param0 context.Context, _param1 *ecr.BatchDeleteImageInput, _param2 ...request.Option) (*ecr.BatchDeleteImageOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "BatchDeleteImageWithContext", varargs...) + ret := _m.ctrl.Call(_m, "BatchDeleteImageWithContext", _s...) ret0, _ := ret[0].(*ecr.BatchDeleteImageOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// BatchDeleteImageWithContext indicates an expected call of BatchDeleteImageWithContext -func (mr *MockECRAPIMockRecorder) BatchDeleteImageWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchDeleteImageWithContext", reflect.TypeOf((*MockECRAPI)(nil).BatchDeleteImageWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) BatchDeleteImageWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchDeleteImageWithContext", _s...) } -// BatchGetImage mocks base method -func (m *MockECRAPI) BatchGetImage(arg0 *ecr.BatchGetImageInput) (*ecr.BatchGetImageOutput, error) { - ret := m.ctrl.Call(m, "BatchGetImage", arg0) +func (_m *MockECRAPI) BatchGetImage(_param0 *ecr.BatchGetImageInput) (*ecr.BatchGetImageOutput, error) { + ret := _m.ctrl.Call(_m, "BatchGetImage", _param0) ret0, _ := ret[0].(*ecr.BatchGetImageOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// BatchGetImage indicates an expected call of BatchGetImage -func (mr *MockECRAPIMockRecorder) BatchGetImage(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchGetImage", reflect.TypeOf((*MockECRAPI)(nil).BatchGetImage), arg0) +func (_mr *_MockECRAPIRecorder) BatchGetImage(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchGetImage", arg0) } -// BatchGetImageRequest mocks base method -func (m *MockECRAPI) BatchGetImageRequest(arg0 *ecr.BatchGetImageInput) (*request.Request, *ecr.BatchGetImageOutput) { - ret := m.ctrl.Call(m, "BatchGetImageRequest", arg0) +func (_m *MockECRAPI) BatchGetImageRequest(_param0 *ecr.BatchGetImageInput) (*request.Request, *ecr.BatchGetImageOutput) { + ret := _m.ctrl.Call(_m, "BatchGetImageRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.BatchGetImageOutput) return ret0, ret1 } -// BatchGetImageRequest indicates an expected call of BatchGetImageRequest -func (mr *MockECRAPIMockRecorder) BatchGetImageRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchGetImageRequest", reflect.TypeOf((*MockECRAPI)(nil).BatchGetImageRequest), arg0) +func (_mr *_MockECRAPIRecorder) BatchGetImageRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchGetImageRequest", arg0) } -// BatchGetImageWithContext mocks base method -func (m *MockECRAPI) BatchGetImageWithContext(arg0 aws.Context, arg1 *ecr.BatchGetImageInput, arg2 ...request.Option) (*ecr.BatchGetImageOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) BatchGetImageWithContext(_param0 context.Context, _param1 *ecr.BatchGetImageInput, _param2 ...request.Option) (*ecr.BatchGetImageOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "BatchGetImageWithContext", varargs...) + ret := _m.ctrl.Call(_m, "BatchGetImageWithContext", _s...) ret0, _ := ret[0].(*ecr.BatchGetImageOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// BatchGetImageWithContext indicates an expected call of BatchGetImageWithContext -func (mr *MockECRAPIMockRecorder) BatchGetImageWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "BatchGetImageWithContext", reflect.TypeOf((*MockECRAPI)(nil).BatchGetImageWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) BatchGetImageWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "BatchGetImageWithContext", _s...) } -// CompleteLayerUpload mocks base method -func (m *MockECRAPI) CompleteLayerUpload(arg0 *ecr.CompleteLayerUploadInput) (*ecr.CompleteLayerUploadOutput, error) { - ret := m.ctrl.Call(m, "CompleteLayerUpload", arg0) +func (_m *MockECRAPI) CompleteLayerUpload(_param0 *ecr.CompleteLayerUploadInput) (*ecr.CompleteLayerUploadOutput, error) { + ret := _m.ctrl.Call(_m, "CompleteLayerUpload", _param0) ret0, _ := ret[0].(*ecr.CompleteLayerUploadOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// CompleteLayerUpload indicates an expected call of CompleteLayerUpload -func (mr *MockECRAPIMockRecorder) CompleteLayerUpload(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CompleteLayerUpload", reflect.TypeOf((*MockECRAPI)(nil).CompleteLayerUpload), arg0) +func (_mr *_MockECRAPIRecorder) CompleteLayerUpload(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "CompleteLayerUpload", arg0) } -// CompleteLayerUploadRequest mocks base method -func (m *MockECRAPI) CompleteLayerUploadRequest(arg0 *ecr.CompleteLayerUploadInput) (*request.Request, *ecr.CompleteLayerUploadOutput) { - ret := m.ctrl.Call(m, "CompleteLayerUploadRequest", arg0) +func (_m *MockECRAPI) CompleteLayerUploadRequest(_param0 *ecr.CompleteLayerUploadInput) (*request.Request, *ecr.CompleteLayerUploadOutput) { + ret := _m.ctrl.Call(_m, "CompleteLayerUploadRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.CompleteLayerUploadOutput) return ret0, ret1 } -// CompleteLayerUploadRequest indicates an expected call of CompleteLayerUploadRequest -func (mr *MockECRAPIMockRecorder) CompleteLayerUploadRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CompleteLayerUploadRequest", reflect.TypeOf((*MockECRAPI)(nil).CompleteLayerUploadRequest), arg0) +func (_mr *_MockECRAPIRecorder) CompleteLayerUploadRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "CompleteLayerUploadRequest", arg0) } -// CompleteLayerUploadWithContext mocks base method -func (m *MockECRAPI) CompleteLayerUploadWithContext(arg0 aws.Context, arg1 *ecr.CompleteLayerUploadInput, arg2 ...request.Option) (*ecr.CompleteLayerUploadOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) CompleteLayerUploadWithContext(_param0 context.Context, _param1 *ecr.CompleteLayerUploadInput, _param2 ...request.Option) (*ecr.CompleteLayerUploadOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "CompleteLayerUploadWithContext", varargs...) + ret := _m.ctrl.Call(_m, "CompleteLayerUploadWithContext", _s...) ret0, _ := ret[0].(*ecr.CompleteLayerUploadOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// CompleteLayerUploadWithContext indicates an expected call of CompleteLayerUploadWithContext -func (mr *MockECRAPIMockRecorder) CompleteLayerUploadWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CompleteLayerUploadWithContext", reflect.TypeOf((*MockECRAPI)(nil).CompleteLayerUploadWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) CompleteLayerUploadWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "CompleteLayerUploadWithContext", _s...) } -// CreateRepository mocks base method -func (m *MockECRAPI) CreateRepository(arg0 *ecr.CreateRepositoryInput) (*ecr.CreateRepositoryOutput, error) { - ret := m.ctrl.Call(m, "CreateRepository", arg0) +func (_m *MockECRAPI) CreateRepository(_param0 *ecr.CreateRepositoryInput) (*ecr.CreateRepositoryOutput, error) { + ret := _m.ctrl.Call(_m, "CreateRepository", _param0) ret0, _ := ret[0].(*ecr.CreateRepositoryOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// CreateRepository indicates an expected call of CreateRepository -func (mr *MockECRAPIMockRecorder) CreateRepository(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRepository", reflect.TypeOf((*MockECRAPI)(nil).CreateRepository), arg0) +func (_mr *_MockECRAPIRecorder) CreateRepository(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "CreateRepository", arg0) } -// CreateRepositoryRequest mocks base method -func (m *MockECRAPI) CreateRepositoryRequest(arg0 *ecr.CreateRepositoryInput) (*request.Request, *ecr.CreateRepositoryOutput) { - ret := m.ctrl.Call(m, "CreateRepositoryRequest", arg0) +func (_m *MockECRAPI) CreateRepositoryRequest(_param0 *ecr.CreateRepositoryInput) (*request.Request, *ecr.CreateRepositoryOutput) { + ret := _m.ctrl.Call(_m, "CreateRepositoryRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.CreateRepositoryOutput) return ret0, ret1 } -// CreateRepositoryRequest indicates an expected call of CreateRepositoryRequest -func (mr *MockECRAPIMockRecorder) CreateRepositoryRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRepositoryRequest", reflect.TypeOf((*MockECRAPI)(nil).CreateRepositoryRequest), arg0) +func (_mr *_MockECRAPIRecorder) CreateRepositoryRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "CreateRepositoryRequest", arg0) } -// CreateRepositoryWithContext mocks base method -func (m *MockECRAPI) CreateRepositoryWithContext(arg0 aws.Context, arg1 *ecr.CreateRepositoryInput, arg2 ...request.Option) (*ecr.CreateRepositoryOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) CreateRepositoryWithContext(_param0 context.Context, _param1 *ecr.CreateRepositoryInput, _param2 ...request.Option) (*ecr.CreateRepositoryOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "CreateRepositoryWithContext", varargs...) + ret := _m.ctrl.Call(_m, "CreateRepositoryWithContext", _s...) ret0, _ := ret[0].(*ecr.CreateRepositoryOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// CreateRepositoryWithContext indicates an expected call of CreateRepositoryWithContext -func (mr *MockECRAPIMockRecorder) CreateRepositoryWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CreateRepositoryWithContext", reflect.TypeOf((*MockECRAPI)(nil).CreateRepositoryWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) CreateRepositoryWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "CreateRepositoryWithContext", _s...) } -// DeleteLifecyclePolicy mocks base method -func (m *MockECRAPI) DeleteLifecyclePolicy(arg0 *ecr.DeleteLifecyclePolicyInput) (*ecr.DeleteLifecyclePolicyOutput, error) { - ret := m.ctrl.Call(m, "DeleteLifecyclePolicy", arg0) +func (_m *MockECRAPI) DeleteLifecyclePolicy(_param0 *ecr.DeleteLifecyclePolicyInput) (*ecr.DeleteLifecyclePolicyOutput, error) { + ret := _m.ctrl.Call(_m, "DeleteLifecyclePolicy", _param0) ret0, _ := ret[0].(*ecr.DeleteLifecyclePolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DeleteLifecyclePolicy indicates an expected call of DeleteLifecyclePolicy -func (mr *MockECRAPIMockRecorder) DeleteLifecyclePolicy(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteLifecyclePolicy", reflect.TypeOf((*MockECRAPI)(nil).DeleteLifecyclePolicy), arg0) +func (_mr *_MockECRAPIRecorder) DeleteLifecyclePolicy(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteLifecyclePolicy", arg0) } -// DeleteLifecyclePolicyRequest mocks base method -func (m *MockECRAPI) DeleteLifecyclePolicyRequest(arg0 *ecr.DeleteLifecyclePolicyInput) (*request.Request, *ecr.DeleteLifecyclePolicyOutput) { - ret := m.ctrl.Call(m, "DeleteLifecyclePolicyRequest", arg0) +func (_m *MockECRAPI) DeleteLifecyclePolicyRequest(_param0 *ecr.DeleteLifecyclePolicyInput) (*request.Request, *ecr.DeleteLifecyclePolicyOutput) { + ret := _m.ctrl.Call(_m, "DeleteLifecyclePolicyRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.DeleteLifecyclePolicyOutput) return ret0, ret1 } -// DeleteLifecyclePolicyRequest indicates an expected call of DeleteLifecyclePolicyRequest -func (mr *MockECRAPIMockRecorder) DeleteLifecyclePolicyRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteLifecyclePolicyRequest", reflect.TypeOf((*MockECRAPI)(nil).DeleteLifecyclePolicyRequest), arg0) +func (_mr *_MockECRAPIRecorder) DeleteLifecyclePolicyRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteLifecyclePolicyRequest", arg0) } -// DeleteLifecyclePolicyWithContext mocks base method -func (m *MockECRAPI) DeleteLifecyclePolicyWithContext(arg0 aws.Context, arg1 *ecr.DeleteLifecyclePolicyInput, arg2 ...request.Option) (*ecr.DeleteLifecyclePolicyOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DeleteLifecyclePolicyWithContext(_param0 context.Context, _param1 *ecr.DeleteLifecyclePolicyInput, _param2 ...request.Option) (*ecr.DeleteLifecyclePolicyOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DeleteLifecyclePolicyWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DeleteLifecyclePolicyWithContext", _s...) ret0, _ := ret[0].(*ecr.DeleteLifecyclePolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DeleteLifecyclePolicyWithContext indicates an expected call of DeleteLifecyclePolicyWithContext -func (mr *MockECRAPIMockRecorder) DeleteLifecyclePolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteLifecyclePolicyWithContext", reflect.TypeOf((*MockECRAPI)(nil).DeleteLifecyclePolicyWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DeleteLifecyclePolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteLifecyclePolicyWithContext", _s...) } -// DeleteRepository mocks base method -func (m *MockECRAPI) DeleteRepository(arg0 *ecr.DeleteRepositoryInput) (*ecr.DeleteRepositoryOutput, error) { - ret := m.ctrl.Call(m, "DeleteRepository", arg0) +func (_m *MockECRAPI) DeleteRepository(_param0 *ecr.DeleteRepositoryInput) (*ecr.DeleteRepositoryOutput, error) { + ret := _m.ctrl.Call(_m, "DeleteRepository", _param0) ret0, _ := ret[0].(*ecr.DeleteRepositoryOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DeleteRepository indicates an expected call of DeleteRepository -func (mr *MockECRAPIMockRecorder) DeleteRepository(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepository", reflect.TypeOf((*MockECRAPI)(nil).DeleteRepository), arg0) +func (_mr *_MockECRAPIRecorder) DeleteRepository(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteRepository", arg0) } -// DeleteRepositoryPolicy mocks base method -func (m *MockECRAPI) DeleteRepositoryPolicy(arg0 *ecr.DeleteRepositoryPolicyInput) (*ecr.DeleteRepositoryPolicyOutput, error) { - ret := m.ctrl.Call(m, "DeleteRepositoryPolicy", arg0) +func (_m *MockECRAPI) DeleteRepositoryPolicy(_param0 *ecr.DeleteRepositoryPolicyInput) (*ecr.DeleteRepositoryPolicyOutput, error) { + ret := _m.ctrl.Call(_m, "DeleteRepositoryPolicy", _param0) ret0, _ := ret[0].(*ecr.DeleteRepositoryPolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DeleteRepositoryPolicy indicates an expected call of DeleteRepositoryPolicy -func (mr *MockECRAPIMockRecorder) DeleteRepositoryPolicy(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepositoryPolicy", reflect.TypeOf((*MockECRAPI)(nil).DeleteRepositoryPolicy), arg0) +func (_mr *_MockECRAPIRecorder) DeleteRepositoryPolicy(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteRepositoryPolicy", arg0) } -// DeleteRepositoryPolicyRequest mocks base method -func (m *MockECRAPI) DeleteRepositoryPolicyRequest(arg0 *ecr.DeleteRepositoryPolicyInput) (*request.Request, *ecr.DeleteRepositoryPolicyOutput) { - ret := m.ctrl.Call(m, "DeleteRepositoryPolicyRequest", arg0) +func (_m *MockECRAPI) DeleteRepositoryPolicyRequest(_param0 *ecr.DeleteRepositoryPolicyInput) (*request.Request, *ecr.DeleteRepositoryPolicyOutput) { + ret := _m.ctrl.Call(_m, "DeleteRepositoryPolicyRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.DeleteRepositoryPolicyOutput) return ret0, ret1 } -// DeleteRepositoryPolicyRequest indicates an expected call of DeleteRepositoryPolicyRequest -func (mr *MockECRAPIMockRecorder) DeleteRepositoryPolicyRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepositoryPolicyRequest", reflect.TypeOf((*MockECRAPI)(nil).DeleteRepositoryPolicyRequest), arg0) +func (_mr *_MockECRAPIRecorder) DeleteRepositoryPolicyRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteRepositoryPolicyRequest", arg0) } -// DeleteRepositoryPolicyWithContext mocks base method -func (m *MockECRAPI) DeleteRepositoryPolicyWithContext(arg0 aws.Context, arg1 *ecr.DeleteRepositoryPolicyInput, arg2 ...request.Option) (*ecr.DeleteRepositoryPolicyOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DeleteRepositoryPolicyWithContext(_param0 context.Context, _param1 *ecr.DeleteRepositoryPolicyInput, _param2 ...request.Option) (*ecr.DeleteRepositoryPolicyOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DeleteRepositoryPolicyWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DeleteRepositoryPolicyWithContext", _s...) ret0, _ := ret[0].(*ecr.DeleteRepositoryPolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DeleteRepositoryPolicyWithContext indicates an expected call of DeleteRepositoryPolicyWithContext -func (mr *MockECRAPIMockRecorder) DeleteRepositoryPolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepositoryPolicyWithContext", reflect.TypeOf((*MockECRAPI)(nil).DeleteRepositoryPolicyWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DeleteRepositoryPolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteRepositoryPolicyWithContext", _s...) } -// DeleteRepositoryRequest mocks base method -func (m *MockECRAPI) DeleteRepositoryRequest(arg0 *ecr.DeleteRepositoryInput) (*request.Request, *ecr.DeleteRepositoryOutput) { - ret := m.ctrl.Call(m, "DeleteRepositoryRequest", arg0) +func (_m *MockECRAPI) DeleteRepositoryRequest(_param0 *ecr.DeleteRepositoryInput) (*request.Request, *ecr.DeleteRepositoryOutput) { + ret := _m.ctrl.Call(_m, "DeleteRepositoryRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.DeleteRepositoryOutput) return ret0, ret1 } -// DeleteRepositoryRequest indicates an expected call of DeleteRepositoryRequest -func (mr *MockECRAPIMockRecorder) DeleteRepositoryRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepositoryRequest", reflect.TypeOf((*MockECRAPI)(nil).DeleteRepositoryRequest), arg0) +func (_mr *_MockECRAPIRecorder) DeleteRepositoryRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteRepositoryRequest", arg0) } -// DeleteRepositoryWithContext mocks base method -func (m *MockECRAPI) DeleteRepositoryWithContext(arg0 aws.Context, arg1 *ecr.DeleteRepositoryInput, arg2 ...request.Option) (*ecr.DeleteRepositoryOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DeleteRepositoryWithContext(_param0 context.Context, _param1 *ecr.DeleteRepositoryInput, _param2 ...request.Option) (*ecr.DeleteRepositoryOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DeleteRepositoryWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DeleteRepositoryWithContext", _s...) ret0, _ := ret[0].(*ecr.DeleteRepositoryOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DeleteRepositoryWithContext indicates an expected call of DeleteRepositoryWithContext -func (mr *MockECRAPIMockRecorder) DeleteRepositoryWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DeleteRepositoryWithContext", reflect.TypeOf((*MockECRAPI)(nil).DeleteRepositoryWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DeleteRepositoryWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DeleteRepositoryWithContext", _s...) } -// DescribeImages mocks base method -func (m *MockECRAPI) DescribeImages(arg0 *ecr.DescribeImagesInput) (*ecr.DescribeImagesOutput, error) { - ret := m.ctrl.Call(m, "DescribeImages", arg0) +func (_m *MockECRAPI) DescribeImages(_param0 *ecr.DescribeImagesInput) (*ecr.DescribeImagesOutput, error) { + ret := _m.ctrl.Call(_m, "DescribeImages", _param0) ret0, _ := ret[0].(*ecr.DescribeImagesOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DescribeImages indicates an expected call of DescribeImages -func (mr *MockECRAPIMockRecorder) DescribeImages(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeImages", reflect.TypeOf((*MockECRAPI)(nil).DescribeImages), arg0) +func (_mr *_MockECRAPIRecorder) DescribeImages(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeImages", arg0) } -// DescribeImagesPages mocks base method -func (m *MockECRAPI) DescribeImagesPages(arg0 *ecr.DescribeImagesInput, arg1 func(*ecr.DescribeImagesOutput, bool) bool) error { - ret := m.ctrl.Call(m, "DescribeImagesPages", arg0, arg1) +func (_m *MockECRAPI) DescribeImagesPages(_param0 *ecr.DescribeImagesInput, _param1 func(*ecr.DescribeImagesOutput, bool) bool) error { + ret := _m.ctrl.Call(_m, "DescribeImagesPages", _param0, _param1) ret0, _ := ret[0].(error) return ret0 } -// DescribeImagesPages indicates an expected call of DescribeImagesPages -func (mr *MockECRAPIMockRecorder) DescribeImagesPages(arg0, arg1 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeImagesPages", reflect.TypeOf((*MockECRAPI)(nil).DescribeImagesPages), arg0, arg1) +func (_mr *_MockECRAPIRecorder) DescribeImagesPages(arg0, arg1 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeImagesPages", arg0, arg1) } -// DescribeImagesPagesWithContext mocks base method -func (m *MockECRAPI) DescribeImagesPagesWithContext(arg0 aws.Context, arg1 *ecr.DescribeImagesInput, arg2 func(*ecr.DescribeImagesOutput, bool) bool, arg3 ...request.Option) error { - varargs := []interface{}{arg0, arg1, arg2} - for _, a := range arg3 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DescribeImagesPagesWithContext(_param0 context.Context, _param1 *ecr.DescribeImagesInput, _param2 func(*ecr.DescribeImagesOutput, bool) bool, _param3 ...request.Option) error { + _s := []interface{}{_param0, _param1, _param2} + for _, _x := range _param3 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DescribeImagesPagesWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DescribeImagesPagesWithContext", _s...) ret0, _ := ret[0].(error) return ret0 } -// DescribeImagesPagesWithContext indicates an expected call of DescribeImagesPagesWithContext -func (mr *MockECRAPIMockRecorder) DescribeImagesPagesWithContext(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1, arg2}, arg3...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeImagesPagesWithContext", reflect.TypeOf((*MockECRAPI)(nil).DescribeImagesPagesWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DescribeImagesPagesWithContext(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1, arg2}, arg3...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeImagesPagesWithContext", _s...) } -// DescribeImagesRequest mocks base method -func (m *MockECRAPI) DescribeImagesRequest(arg0 *ecr.DescribeImagesInput) (*request.Request, *ecr.DescribeImagesOutput) { - ret := m.ctrl.Call(m, "DescribeImagesRequest", arg0) +func (_m *MockECRAPI) DescribeImagesRequest(_param0 *ecr.DescribeImagesInput) (*request.Request, *ecr.DescribeImagesOutput) { + ret := _m.ctrl.Call(_m, "DescribeImagesRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.DescribeImagesOutput) return ret0, ret1 } -// DescribeImagesRequest indicates an expected call of DescribeImagesRequest -func (mr *MockECRAPIMockRecorder) DescribeImagesRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeImagesRequest", reflect.TypeOf((*MockECRAPI)(nil).DescribeImagesRequest), arg0) +func (_mr *_MockECRAPIRecorder) DescribeImagesRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeImagesRequest", arg0) } -// DescribeImagesWithContext mocks base method -func (m *MockECRAPI) DescribeImagesWithContext(arg0 aws.Context, arg1 *ecr.DescribeImagesInput, arg2 ...request.Option) (*ecr.DescribeImagesOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DescribeImagesWithContext(_param0 context.Context, _param1 *ecr.DescribeImagesInput, _param2 ...request.Option) (*ecr.DescribeImagesOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DescribeImagesWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DescribeImagesWithContext", _s...) ret0, _ := ret[0].(*ecr.DescribeImagesOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DescribeImagesWithContext indicates an expected call of DescribeImagesWithContext -func (mr *MockECRAPIMockRecorder) DescribeImagesWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeImagesWithContext", reflect.TypeOf((*MockECRAPI)(nil).DescribeImagesWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DescribeImagesWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeImagesWithContext", _s...) } -// DescribeRepositories mocks base method -func (m *MockECRAPI) DescribeRepositories(arg0 *ecr.DescribeRepositoriesInput) (*ecr.DescribeRepositoriesOutput, error) { - ret := m.ctrl.Call(m, "DescribeRepositories", arg0) +func (_m *MockECRAPI) DescribeRepositories(_param0 *ecr.DescribeRepositoriesInput) (*ecr.DescribeRepositoriesOutput, error) { + ret := _m.ctrl.Call(_m, "DescribeRepositories", _param0) ret0, _ := ret[0].(*ecr.DescribeRepositoriesOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DescribeRepositories indicates an expected call of DescribeRepositories -func (mr *MockECRAPIMockRecorder) DescribeRepositories(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepositories", reflect.TypeOf((*MockECRAPI)(nil).DescribeRepositories), arg0) +func (_mr *_MockECRAPIRecorder) DescribeRepositories(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeRepositories", arg0) } -// DescribeRepositoriesPages mocks base method -func (m *MockECRAPI) DescribeRepositoriesPages(arg0 *ecr.DescribeRepositoriesInput, arg1 func(*ecr.DescribeRepositoriesOutput, bool) bool) error { - ret := m.ctrl.Call(m, "DescribeRepositoriesPages", arg0, arg1) +func (_m *MockECRAPI) DescribeRepositoriesPages(_param0 *ecr.DescribeRepositoriesInput, _param1 func(*ecr.DescribeRepositoriesOutput, bool) bool) error { + ret := _m.ctrl.Call(_m, "DescribeRepositoriesPages", _param0, _param1) ret0, _ := ret[0].(error) return ret0 } -// DescribeRepositoriesPages indicates an expected call of DescribeRepositoriesPages -func (mr *MockECRAPIMockRecorder) DescribeRepositoriesPages(arg0, arg1 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepositoriesPages", reflect.TypeOf((*MockECRAPI)(nil).DescribeRepositoriesPages), arg0, arg1) +func (_mr *_MockECRAPIRecorder) DescribeRepositoriesPages(arg0, arg1 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeRepositoriesPages", arg0, arg1) } -// DescribeRepositoriesPagesWithContext mocks base method -func (m *MockECRAPI) DescribeRepositoriesPagesWithContext(arg0 aws.Context, arg1 *ecr.DescribeRepositoriesInput, arg2 func(*ecr.DescribeRepositoriesOutput, bool) bool, arg3 ...request.Option) error { - varargs := []interface{}{arg0, arg1, arg2} - for _, a := range arg3 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DescribeRepositoriesPagesWithContext(_param0 context.Context, _param1 *ecr.DescribeRepositoriesInput, _param2 func(*ecr.DescribeRepositoriesOutput, bool) bool, _param3 ...request.Option) error { + _s := []interface{}{_param0, _param1, _param2} + for _, _x := range _param3 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DescribeRepositoriesPagesWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DescribeRepositoriesPagesWithContext", _s...) ret0, _ := ret[0].(error) return ret0 } -// DescribeRepositoriesPagesWithContext indicates an expected call of DescribeRepositoriesPagesWithContext -func (mr *MockECRAPIMockRecorder) DescribeRepositoriesPagesWithContext(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1, arg2}, arg3...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepositoriesPagesWithContext", reflect.TypeOf((*MockECRAPI)(nil).DescribeRepositoriesPagesWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DescribeRepositoriesPagesWithContext(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1, arg2}, arg3...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeRepositoriesPagesWithContext", _s...) } -// DescribeRepositoriesRequest mocks base method -func (m *MockECRAPI) DescribeRepositoriesRequest(arg0 *ecr.DescribeRepositoriesInput) (*request.Request, *ecr.DescribeRepositoriesOutput) { - ret := m.ctrl.Call(m, "DescribeRepositoriesRequest", arg0) +func (_m *MockECRAPI) DescribeRepositoriesRequest(_param0 *ecr.DescribeRepositoriesInput) (*request.Request, *ecr.DescribeRepositoriesOutput) { + ret := _m.ctrl.Call(_m, "DescribeRepositoriesRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.DescribeRepositoriesOutput) return ret0, ret1 } -// DescribeRepositoriesRequest indicates an expected call of DescribeRepositoriesRequest -func (mr *MockECRAPIMockRecorder) DescribeRepositoriesRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepositoriesRequest", reflect.TypeOf((*MockECRAPI)(nil).DescribeRepositoriesRequest), arg0) +func (_mr *_MockECRAPIRecorder) DescribeRepositoriesRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeRepositoriesRequest", arg0) } -// DescribeRepositoriesWithContext mocks base method -func (m *MockECRAPI) DescribeRepositoriesWithContext(arg0 aws.Context, arg1 *ecr.DescribeRepositoriesInput, arg2 ...request.Option) (*ecr.DescribeRepositoriesOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) DescribeRepositoriesWithContext(_param0 context.Context, _param1 *ecr.DescribeRepositoriesInput, _param2 ...request.Option) (*ecr.DescribeRepositoriesOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "DescribeRepositoriesWithContext", varargs...) + ret := _m.ctrl.Call(_m, "DescribeRepositoriesWithContext", _s...) ret0, _ := ret[0].(*ecr.DescribeRepositoriesOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// DescribeRepositoriesWithContext indicates an expected call of DescribeRepositoriesWithContext -func (mr *MockECRAPIMockRecorder) DescribeRepositoriesWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DescribeRepositoriesWithContext", reflect.TypeOf((*MockECRAPI)(nil).DescribeRepositoriesWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) DescribeRepositoriesWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "DescribeRepositoriesWithContext", _s...) } -// GetAuthorizationToken mocks base method -func (m *MockECRAPI) GetAuthorizationToken(arg0 *ecr.GetAuthorizationTokenInput) (*ecr.GetAuthorizationTokenOutput, error) { - ret := m.ctrl.Call(m, "GetAuthorizationToken", arg0) +func (_m *MockECRAPI) GetAuthorizationToken(_param0 *ecr.GetAuthorizationTokenInput) (*ecr.GetAuthorizationTokenOutput, error) { + ret := _m.ctrl.Call(_m, "GetAuthorizationToken", _param0) ret0, _ := ret[0].(*ecr.GetAuthorizationTokenOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetAuthorizationToken indicates an expected call of GetAuthorizationToken -func (mr *MockECRAPIMockRecorder) GetAuthorizationToken(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAuthorizationToken", reflect.TypeOf((*MockECRAPI)(nil).GetAuthorizationToken), arg0) +func (_mr *_MockECRAPIRecorder) GetAuthorizationToken(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetAuthorizationToken", arg0) } -// GetAuthorizationTokenRequest mocks base method -func (m *MockECRAPI) GetAuthorizationTokenRequest(arg0 *ecr.GetAuthorizationTokenInput) (*request.Request, *ecr.GetAuthorizationTokenOutput) { - ret := m.ctrl.Call(m, "GetAuthorizationTokenRequest", arg0) +func (_m *MockECRAPI) GetAuthorizationTokenRequest(_param0 *ecr.GetAuthorizationTokenInput) (*request.Request, *ecr.GetAuthorizationTokenOutput) { + ret := _m.ctrl.Call(_m, "GetAuthorizationTokenRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.GetAuthorizationTokenOutput) return ret0, ret1 } -// GetAuthorizationTokenRequest indicates an expected call of GetAuthorizationTokenRequest -func (mr *MockECRAPIMockRecorder) GetAuthorizationTokenRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAuthorizationTokenRequest", reflect.TypeOf((*MockECRAPI)(nil).GetAuthorizationTokenRequest), arg0) +func (_mr *_MockECRAPIRecorder) GetAuthorizationTokenRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetAuthorizationTokenRequest", arg0) } -// GetAuthorizationTokenWithContext mocks base method -func (m *MockECRAPI) GetAuthorizationTokenWithContext(arg0 aws.Context, arg1 *ecr.GetAuthorizationTokenInput, arg2 ...request.Option) (*ecr.GetAuthorizationTokenOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) GetAuthorizationTokenWithContext(_param0 context.Context, _param1 *ecr.GetAuthorizationTokenInput, _param2 ...request.Option) (*ecr.GetAuthorizationTokenOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "GetAuthorizationTokenWithContext", varargs...) + ret := _m.ctrl.Call(_m, "GetAuthorizationTokenWithContext", _s...) ret0, _ := ret[0].(*ecr.GetAuthorizationTokenOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetAuthorizationTokenWithContext indicates an expected call of GetAuthorizationTokenWithContext -func (mr *MockECRAPIMockRecorder) GetAuthorizationTokenWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetAuthorizationTokenWithContext", reflect.TypeOf((*MockECRAPI)(nil).GetAuthorizationTokenWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) GetAuthorizationTokenWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetAuthorizationTokenWithContext", _s...) } -// GetDownloadUrlForLayer mocks base method -func (m *MockECRAPI) GetDownloadUrlForLayer(arg0 *ecr.GetDownloadUrlForLayerInput) (*ecr.GetDownloadUrlForLayerOutput, error) { - ret := m.ctrl.Call(m, "GetDownloadUrlForLayer", arg0) +func (_m *MockECRAPI) GetDownloadUrlForLayer(_param0 *ecr.GetDownloadUrlForLayerInput) (*ecr.GetDownloadUrlForLayerOutput, error) { + ret := _m.ctrl.Call(_m, "GetDownloadUrlForLayer", _param0) ret0, _ := ret[0].(*ecr.GetDownloadUrlForLayerOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetDownloadUrlForLayer indicates an expected call of GetDownloadUrlForLayer -func (mr *MockECRAPIMockRecorder) GetDownloadUrlForLayer(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetDownloadUrlForLayer", reflect.TypeOf((*MockECRAPI)(nil).GetDownloadUrlForLayer), arg0) +func (_mr *_MockECRAPIRecorder) GetDownloadUrlForLayer(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetDownloadUrlForLayer", arg0) } -// GetDownloadUrlForLayerRequest mocks base method -func (m *MockECRAPI) GetDownloadUrlForLayerRequest(arg0 *ecr.GetDownloadUrlForLayerInput) (*request.Request, *ecr.GetDownloadUrlForLayerOutput) { - ret := m.ctrl.Call(m, "GetDownloadUrlForLayerRequest", arg0) +func (_m *MockECRAPI) GetDownloadUrlForLayerRequest(_param0 *ecr.GetDownloadUrlForLayerInput) (*request.Request, *ecr.GetDownloadUrlForLayerOutput) { + ret := _m.ctrl.Call(_m, "GetDownloadUrlForLayerRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.GetDownloadUrlForLayerOutput) return ret0, ret1 } -// GetDownloadUrlForLayerRequest indicates an expected call of GetDownloadUrlForLayerRequest -func (mr *MockECRAPIMockRecorder) GetDownloadUrlForLayerRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetDownloadUrlForLayerRequest", reflect.TypeOf((*MockECRAPI)(nil).GetDownloadUrlForLayerRequest), arg0) +func (_mr *_MockECRAPIRecorder) GetDownloadUrlForLayerRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetDownloadUrlForLayerRequest", arg0) } -// GetDownloadUrlForLayerWithContext mocks base method -func (m *MockECRAPI) GetDownloadUrlForLayerWithContext(arg0 aws.Context, arg1 *ecr.GetDownloadUrlForLayerInput, arg2 ...request.Option) (*ecr.GetDownloadUrlForLayerOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) GetDownloadUrlForLayerWithContext(_param0 context.Context, _param1 *ecr.GetDownloadUrlForLayerInput, _param2 ...request.Option) (*ecr.GetDownloadUrlForLayerOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "GetDownloadUrlForLayerWithContext", varargs...) + ret := _m.ctrl.Call(_m, "GetDownloadUrlForLayerWithContext", _s...) ret0, _ := ret[0].(*ecr.GetDownloadUrlForLayerOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetDownloadUrlForLayerWithContext indicates an expected call of GetDownloadUrlForLayerWithContext -func (mr *MockECRAPIMockRecorder) GetDownloadUrlForLayerWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetDownloadUrlForLayerWithContext", reflect.TypeOf((*MockECRAPI)(nil).GetDownloadUrlForLayerWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) GetDownloadUrlForLayerWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetDownloadUrlForLayerWithContext", _s...) } -// GetLifecyclePolicy mocks base method -func (m *MockECRAPI) GetLifecyclePolicy(arg0 *ecr.GetLifecyclePolicyInput) (*ecr.GetLifecyclePolicyOutput, error) { - ret := m.ctrl.Call(m, "GetLifecyclePolicy", arg0) +func (_m *MockECRAPI) GetLifecyclePolicy(_param0 *ecr.GetLifecyclePolicyInput) (*ecr.GetLifecyclePolicyOutput, error) { + ret := _m.ctrl.Call(_m, "GetLifecyclePolicy", _param0) ret0, _ := ret[0].(*ecr.GetLifecyclePolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetLifecyclePolicy indicates an expected call of GetLifecyclePolicy -func (mr *MockECRAPIMockRecorder) GetLifecyclePolicy(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLifecyclePolicy", reflect.TypeOf((*MockECRAPI)(nil).GetLifecyclePolicy), arg0) +func (_mr *_MockECRAPIRecorder) GetLifecyclePolicy(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetLifecyclePolicy", arg0) } -// GetLifecyclePolicyPreview mocks base method -func (m *MockECRAPI) GetLifecyclePolicyPreview(arg0 *ecr.GetLifecyclePolicyPreviewInput) (*ecr.GetLifecyclePolicyPreviewOutput, error) { - ret := m.ctrl.Call(m, "GetLifecyclePolicyPreview", arg0) +func (_m *MockECRAPI) GetLifecyclePolicyPreview(_param0 *ecr.GetLifecyclePolicyPreviewInput) (*ecr.GetLifecyclePolicyPreviewOutput, error) { + ret := _m.ctrl.Call(_m, "GetLifecyclePolicyPreview", _param0) ret0, _ := ret[0].(*ecr.GetLifecyclePolicyPreviewOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetLifecyclePolicyPreview indicates an expected call of GetLifecyclePolicyPreview -func (mr *MockECRAPIMockRecorder) GetLifecyclePolicyPreview(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLifecyclePolicyPreview", reflect.TypeOf((*MockECRAPI)(nil).GetLifecyclePolicyPreview), arg0) +func (_mr *_MockECRAPIRecorder) GetLifecyclePolicyPreview(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetLifecyclePolicyPreview", arg0) } -// GetLifecyclePolicyPreviewRequest mocks base method -func (m *MockECRAPI) GetLifecyclePolicyPreviewRequest(arg0 *ecr.GetLifecyclePolicyPreviewInput) (*request.Request, *ecr.GetLifecyclePolicyPreviewOutput) { - ret := m.ctrl.Call(m, "GetLifecyclePolicyPreviewRequest", arg0) +func (_m *MockECRAPI) GetLifecyclePolicyPreviewRequest(_param0 *ecr.GetLifecyclePolicyPreviewInput) (*request.Request, *ecr.GetLifecyclePolicyPreviewOutput) { + ret := _m.ctrl.Call(_m, "GetLifecyclePolicyPreviewRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.GetLifecyclePolicyPreviewOutput) return ret0, ret1 } -// GetLifecyclePolicyPreviewRequest indicates an expected call of GetLifecyclePolicyPreviewRequest -func (mr *MockECRAPIMockRecorder) GetLifecyclePolicyPreviewRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLifecyclePolicyPreviewRequest", reflect.TypeOf((*MockECRAPI)(nil).GetLifecyclePolicyPreviewRequest), arg0) +func (_mr *_MockECRAPIRecorder) GetLifecyclePolicyPreviewRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetLifecyclePolicyPreviewRequest", arg0) } -// GetLifecyclePolicyPreviewWithContext mocks base method -func (m *MockECRAPI) GetLifecyclePolicyPreviewWithContext(arg0 aws.Context, arg1 *ecr.GetLifecyclePolicyPreviewInput, arg2 ...request.Option) (*ecr.GetLifecyclePolicyPreviewOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) GetLifecyclePolicyPreviewWithContext(_param0 context.Context, _param1 *ecr.GetLifecyclePolicyPreviewInput, _param2 ...request.Option) (*ecr.GetLifecyclePolicyPreviewOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "GetLifecyclePolicyPreviewWithContext", varargs...) + ret := _m.ctrl.Call(_m, "GetLifecyclePolicyPreviewWithContext", _s...) ret0, _ := ret[0].(*ecr.GetLifecyclePolicyPreviewOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetLifecyclePolicyPreviewWithContext indicates an expected call of GetLifecyclePolicyPreviewWithContext -func (mr *MockECRAPIMockRecorder) GetLifecyclePolicyPreviewWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLifecyclePolicyPreviewWithContext", reflect.TypeOf((*MockECRAPI)(nil).GetLifecyclePolicyPreviewWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) GetLifecyclePolicyPreviewWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetLifecyclePolicyPreviewWithContext", _s...) } -// GetLifecyclePolicyRequest mocks base method -func (m *MockECRAPI) GetLifecyclePolicyRequest(arg0 *ecr.GetLifecyclePolicyInput) (*request.Request, *ecr.GetLifecyclePolicyOutput) { - ret := m.ctrl.Call(m, "GetLifecyclePolicyRequest", arg0) +func (_m *MockECRAPI) GetLifecyclePolicyRequest(_param0 *ecr.GetLifecyclePolicyInput) (*request.Request, *ecr.GetLifecyclePolicyOutput) { + ret := _m.ctrl.Call(_m, "GetLifecyclePolicyRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.GetLifecyclePolicyOutput) return ret0, ret1 } -// GetLifecyclePolicyRequest indicates an expected call of GetLifecyclePolicyRequest -func (mr *MockECRAPIMockRecorder) GetLifecyclePolicyRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLifecyclePolicyRequest", reflect.TypeOf((*MockECRAPI)(nil).GetLifecyclePolicyRequest), arg0) +func (_mr *_MockECRAPIRecorder) GetLifecyclePolicyRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetLifecyclePolicyRequest", arg0) } -// GetLifecyclePolicyWithContext mocks base method -func (m *MockECRAPI) GetLifecyclePolicyWithContext(arg0 aws.Context, arg1 *ecr.GetLifecyclePolicyInput, arg2 ...request.Option) (*ecr.GetLifecyclePolicyOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) GetLifecyclePolicyWithContext(_param0 context.Context, _param1 *ecr.GetLifecyclePolicyInput, _param2 ...request.Option) (*ecr.GetLifecyclePolicyOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "GetLifecyclePolicyWithContext", varargs...) + ret := _m.ctrl.Call(_m, "GetLifecyclePolicyWithContext", _s...) ret0, _ := ret[0].(*ecr.GetLifecyclePolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetLifecyclePolicyWithContext indicates an expected call of GetLifecyclePolicyWithContext -func (mr *MockECRAPIMockRecorder) GetLifecyclePolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLifecyclePolicyWithContext", reflect.TypeOf((*MockECRAPI)(nil).GetLifecyclePolicyWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) GetLifecyclePolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetLifecyclePolicyWithContext", _s...) } -// GetRepositoryPolicy mocks base method -func (m *MockECRAPI) GetRepositoryPolicy(arg0 *ecr.GetRepositoryPolicyInput) (*ecr.GetRepositoryPolicyOutput, error) { - ret := m.ctrl.Call(m, "GetRepositoryPolicy", arg0) +func (_m *MockECRAPI) GetRepositoryPolicy(_param0 *ecr.GetRepositoryPolicyInput) (*ecr.GetRepositoryPolicyOutput, error) { + ret := _m.ctrl.Call(_m, "GetRepositoryPolicy", _param0) ret0, _ := ret[0].(*ecr.GetRepositoryPolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetRepositoryPolicy indicates an expected call of GetRepositoryPolicy -func (mr *MockECRAPIMockRecorder) GetRepositoryPolicy(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetRepositoryPolicy", reflect.TypeOf((*MockECRAPI)(nil).GetRepositoryPolicy), arg0) +func (_mr *_MockECRAPIRecorder) GetRepositoryPolicy(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetRepositoryPolicy", arg0) } -// GetRepositoryPolicyRequest mocks base method -func (m *MockECRAPI) GetRepositoryPolicyRequest(arg0 *ecr.GetRepositoryPolicyInput) (*request.Request, *ecr.GetRepositoryPolicyOutput) { - ret := m.ctrl.Call(m, "GetRepositoryPolicyRequest", arg0) +func (_m *MockECRAPI) GetRepositoryPolicyRequest(_param0 *ecr.GetRepositoryPolicyInput) (*request.Request, *ecr.GetRepositoryPolicyOutput) { + ret := _m.ctrl.Call(_m, "GetRepositoryPolicyRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.GetRepositoryPolicyOutput) return ret0, ret1 } -// GetRepositoryPolicyRequest indicates an expected call of GetRepositoryPolicyRequest -func (mr *MockECRAPIMockRecorder) GetRepositoryPolicyRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetRepositoryPolicyRequest", reflect.TypeOf((*MockECRAPI)(nil).GetRepositoryPolicyRequest), arg0) +func (_mr *_MockECRAPIRecorder) GetRepositoryPolicyRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetRepositoryPolicyRequest", arg0) } -// GetRepositoryPolicyWithContext mocks base method -func (m *MockECRAPI) GetRepositoryPolicyWithContext(arg0 aws.Context, arg1 *ecr.GetRepositoryPolicyInput, arg2 ...request.Option) (*ecr.GetRepositoryPolicyOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) GetRepositoryPolicyWithContext(_param0 context.Context, _param1 *ecr.GetRepositoryPolicyInput, _param2 ...request.Option) (*ecr.GetRepositoryPolicyOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "GetRepositoryPolicyWithContext", varargs...) + ret := _m.ctrl.Call(_m, "GetRepositoryPolicyWithContext", _s...) ret0, _ := ret[0].(*ecr.GetRepositoryPolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetRepositoryPolicyWithContext indicates an expected call of GetRepositoryPolicyWithContext -func (mr *MockECRAPIMockRecorder) GetRepositoryPolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetRepositoryPolicyWithContext", reflect.TypeOf((*MockECRAPI)(nil).GetRepositoryPolicyWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) GetRepositoryPolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetRepositoryPolicyWithContext", _s...) } -// InitiateLayerUpload mocks base method -func (m *MockECRAPI) InitiateLayerUpload(arg0 *ecr.InitiateLayerUploadInput) (*ecr.InitiateLayerUploadOutput, error) { - ret := m.ctrl.Call(m, "InitiateLayerUpload", arg0) +func (_m *MockECRAPI) InitiateLayerUpload(_param0 *ecr.InitiateLayerUploadInput) (*ecr.InitiateLayerUploadOutput, error) { + ret := _m.ctrl.Call(_m, "InitiateLayerUpload", _param0) ret0, _ := ret[0].(*ecr.InitiateLayerUploadOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// InitiateLayerUpload indicates an expected call of InitiateLayerUpload -func (mr *MockECRAPIMockRecorder) InitiateLayerUpload(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InitiateLayerUpload", reflect.TypeOf((*MockECRAPI)(nil).InitiateLayerUpload), arg0) +func (_mr *_MockECRAPIRecorder) InitiateLayerUpload(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "InitiateLayerUpload", arg0) } -// InitiateLayerUploadRequest mocks base method -func (m *MockECRAPI) InitiateLayerUploadRequest(arg0 *ecr.InitiateLayerUploadInput) (*request.Request, *ecr.InitiateLayerUploadOutput) { - ret := m.ctrl.Call(m, "InitiateLayerUploadRequest", arg0) +func (_m *MockECRAPI) InitiateLayerUploadRequest(_param0 *ecr.InitiateLayerUploadInput) (*request.Request, *ecr.InitiateLayerUploadOutput) { + ret := _m.ctrl.Call(_m, "InitiateLayerUploadRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.InitiateLayerUploadOutput) return ret0, ret1 } -// InitiateLayerUploadRequest indicates an expected call of InitiateLayerUploadRequest -func (mr *MockECRAPIMockRecorder) InitiateLayerUploadRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InitiateLayerUploadRequest", reflect.TypeOf((*MockECRAPI)(nil).InitiateLayerUploadRequest), arg0) +func (_mr *_MockECRAPIRecorder) InitiateLayerUploadRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "InitiateLayerUploadRequest", arg0) } -// InitiateLayerUploadWithContext mocks base method -func (m *MockECRAPI) InitiateLayerUploadWithContext(arg0 aws.Context, arg1 *ecr.InitiateLayerUploadInput, arg2 ...request.Option) (*ecr.InitiateLayerUploadOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) InitiateLayerUploadWithContext(_param0 context.Context, _param1 *ecr.InitiateLayerUploadInput, _param2 ...request.Option) (*ecr.InitiateLayerUploadOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "InitiateLayerUploadWithContext", varargs...) + ret := _m.ctrl.Call(_m, "InitiateLayerUploadWithContext", _s...) ret0, _ := ret[0].(*ecr.InitiateLayerUploadOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// InitiateLayerUploadWithContext indicates an expected call of InitiateLayerUploadWithContext -func (mr *MockECRAPIMockRecorder) InitiateLayerUploadWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InitiateLayerUploadWithContext", reflect.TypeOf((*MockECRAPI)(nil).InitiateLayerUploadWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) InitiateLayerUploadWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "InitiateLayerUploadWithContext", _s...) } -// ListImages mocks base method -func (m *MockECRAPI) ListImages(arg0 *ecr.ListImagesInput) (*ecr.ListImagesOutput, error) { - ret := m.ctrl.Call(m, "ListImages", arg0) +func (_m *MockECRAPI) ListImages(_param0 *ecr.ListImagesInput) (*ecr.ListImagesOutput, error) { + ret := _m.ctrl.Call(_m, "ListImages", _param0) ret0, _ := ret[0].(*ecr.ListImagesOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// ListImages indicates an expected call of ListImages -func (mr *MockECRAPIMockRecorder) ListImages(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListImages", reflect.TypeOf((*MockECRAPI)(nil).ListImages), arg0) +func (_mr *_MockECRAPIRecorder) ListImages(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListImages", arg0) } -// ListImagesPages mocks base method -func (m *MockECRAPI) ListImagesPages(arg0 *ecr.ListImagesInput, arg1 func(*ecr.ListImagesOutput, bool) bool) error { - ret := m.ctrl.Call(m, "ListImagesPages", arg0, arg1) +func (_m *MockECRAPI) ListImagesPages(_param0 *ecr.ListImagesInput, _param1 func(*ecr.ListImagesOutput, bool) bool) error { + ret := _m.ctrl.Call(_m, "ListImagesPages", _param0, _param1) ret0, _ := ret[0].(error) return ret0 } -// ListImagesPages indicates an expected call of ListImagesPages -func (mr *MockECRAPIMockRecorder) ListImagesPages(arg0, arg1 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListImagesPages", reflect.TypeOf((*MockECRAPI)(nil).ListImagesPages), arg0, arg1) +func (_mr *_MockECRAPIRecorder) ListImagesPages(arg0, arg1 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListImagesPages", arg0, arg1) } -// ListImagesPagesWithContext mocks base method -func (m *MockECRAPI) ListImagesPagesWithContext(arg0 aws.Context, arg1 *ecr.ListImagesInput, arg2 func(*ecr.ListImagesOutput, bool) bool, arg3 ...request.Option) error { - varargs := []interface{}{arg0, arg1, arg2} - for _, a := range arg3 { - varargs = append(varargs, a) +func (_m *MockECRAPI) ListImagesPagesWithContext(_param0 context.Context, _param1 *ecr.ListImagesInput, _param2 func(*ecr.ListImagesOutput, bool) bool, _param3 ...request.Option) error { + _s := []interface{}{_param0, _param1, _param2} + for _, _x := range _param3 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "ListImagesPagesWithContext", varargs...) + ret := _m.ctrl.Call(_m, "ListImagesPagesWithContext", _s...) ret0, _ := ret[0].(error) return ret0 } -// ListImagesPagesWithContext indicates an expected call of ListImagesPagesWithContext -func (mr *MockECRAPIMockRecorder) ListImagesPagesWithContext(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1, arg2}, arg3...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListImagesPagesWithContext", reflect.TypeOf((*MockECRAPI)(nil).ListImagesPagesWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) ListImagesPagesWithContext(arg0, arg1, arg2 interface{}, arg3 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1, arg2}, arg3...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListImagesPagesWithContext", _s...) } -// ListImagesRequest mocks base method -func (m *MockECRAPI) ListImagesRequest(arg0 *ecr.ListImagesInput) (*request.Request, *ecr.ListImagesOutput) { - ret := m.ctrl.Call(m, "ListImagesRequest", arg0) +func (_m *MockECRAPI) ListImagesRequest(_param0 *ecr.ListImagesInput) (*request.Request, *ecr.ListImagesOutput) { + ret := _m.ctrl.Call(_m, "ListImagesRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.ListImagesOutput) return ret0, ret1 } -// ListImagesRequest indicates an expected call of ListImagesRequest -func (mr *MockECRAPIMockRecorder) ListImagesRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListImagesRequest", reflect.TypeOf((*MockECRAPI)(nil).ListImagesRequest), arg0) +func (_mr *_MockECRAPIRecorder) ListImagesRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListImagesRequest", arg0) } -// ListImagesWithContext mocks base method -func (m *MockECRAPI) ListImagesWithContext(arg0 aws.Context, arg1 *ecr.ListImagesInput, arg2 ...request.Option) (*ecr.ListImagesOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) ListImagesWithContext(_param0 context.Context, _param1 *ecr.ListImagesInput, _param2 ...request.Option) (*ecr.ListImagesOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "ListImagesWithContext", varargs...) + ret := _m.ctrl.Call(_m, "ListImagesWithContext", _s...) ret0, _ := ret[0].(*ecr.ListImagesOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// ListImagesWithContext indicates an expected call of ListImagesWithContext -func (mr *MockECRAPIMockRecorder) ListImagesWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListImagesWithContext", reflect.TypeOf((*MockECRAPI)(nil).ListImagesWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) ListImagesWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListImagesWithContext", _s...) } -// PutImage mocks base method -func (m *MockECRAPI) PutImage(arg0 *ecr.PutImageInput) (*ecr.PutImageOutput, error) { - ret := m.ctrl.Call(m, "PutImage", arg0) +func (_m *MockECRAPI) ListTagsForResource(_param0 *ecr.ListTagsForResourceInput) (*ecr.ListTagsForResourceOutput, error) { + ret := _m.ctrl.Call(_m, "ListTagsForResource", _param0) + ret0, _ := ret[0].(*ecr.ListTagsForResourceOutput) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) ListTagsForResource(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListTagsForResource", arg0) +} + +func (_m *MockECRAPI) ListTagsForResourceRequest(_param0 *ecr.ListTagsForResourceInput) (*request.Request, *ecr.ListTagsForResourceOutput) { + ret := _m.ctrl.Call(_m, "ListTagsForResourceRequest", _param0) + ret0, _ := ret[0].(*request.Request) + ret1, _ := ret[1].(*ecr.ListTagsForResourceOutput) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) ListTagsForResourceRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListTagsForResourceRequest", arg0) +} + +func (_m *MockECRAPI) ListTagsForResourceWithContext(_param0 context.Context, _param1 *ecr.ListTagsForResourceInput, _param2 ...request.Option) (*ecr.ListTagsForResourceOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) + } + ret := _m.ctrl.Call(_m, "ListTagsForResourceWithContext", _s...) + ret0, _ := ret[0].(*ecr.ListTagsForResourceOutput) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) ListTagsForResourceWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListTagsForResourceWithContext", _s...) +} + +func (_m *MockECRAPI) PutImage(_param0 *ecr.PutImageInput) (*ecr.PutImageOutput, error) { + ret := _m.ctrl.Call(_m, "PutImage", _param0) ret0, _ := ret[0].(*ecr.PutImageOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// PutImage indicates an expected call of PutImage -func (mr *MockECRAPIMockRecorder) PutImage(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutImage", reflect.TypeOf((*MockECRAPI)(nil).PutImage), arg0) +func (_mr *_MockECRAPIRecorder) PutImage(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "PutImage", arg0) } -// PutImageRequest mocks base method -func (m *MockECRAPI) PutImageRequest(arg0 *ecr.PutImageInput) (*request.Request, *ecr.PutImageOutput) { - ret := m.ctrl.Call(m, "PutImageRequest", arg0) +func (_m *MockECRAPI) PutImageRequest(_param0 *ecr.PutImageInput) (*request.Request, *ecr.PutImageOutput) { + ret := _m.ctrl.Call(_m, "PutImageRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.PutImageOutput) return ret0, ret1 } -// PutImageRequest indicates an expected call of PutImageRequest -func (mr *MockECRAPIMockRecorder) PutImageRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutImageRequest", reflect.TypeOf((*MockECRAPI)(nil).PutImageRequest), arg0) +func (_mr *_MockECRAPIRecorder) PutImageRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "PutImageRequest", arg0) } -// PutImageWithContext mocks base method -func (m *MockECRAPI) PutImageWithContext(arg0 aws.Context, arg1 *ecr.PutImageInput, arg2 ...request.Option) (*ecr.PutImageOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) PutImageWithContext(_param0 context.Context, _param1 *ecr.PutImageInput, _param2 ...request.Option) (*ecr.PutImageOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "PutImageWithContext", varargs...) + ret := _m.ctrl.Call(_m, "PutImageWithContext", _s...) ret0, _ := ret[0].(*ecr.PutImageOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// PutImageWithContext indicates an expected call of PutImageWithContext -func (mr *MockECRAPIMockRecorder) PutImageWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutImageWithContext", reflect.TypeOf((*MockECRAPI)(nil).PutImageWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) PutImageWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "PutImageWithContext", _s...) } -// PutLifecyclePolicy mocks base method -func (m *MockECRAPI) PutLifecyclePolicy(arg0 *ecr.PutLifecyclePolicyInput) (*ecr.PutLifecyclePolicyOutput, error) { - ret := m.ctrl.Call(m, "PutLifecyclePolicy", arg0) +func (_m *MockECRAPI) PutLifecyclePolicy(_param0 *ecr.PutLifecyclePolicyInput) (*ecr.PutLifecyclePolicyOutput, error) { + ret := _m.ctrl.Call(_m, "PutLifecyclePolicy", _param0) ret0, _ := ret[0].(*ecr.PutLifecyclePolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// PutLifecyclePolicy indicates an expected call of PutLifecyclePolicy -func (mr *MockECRAPIMockRecorder) PutLifecyclePolicy(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutLifecyclePolicy", reflect.TypeOf((*MockECRAPI)(nil).PutLifecyclePolicy), arg0) +func (_mr *_MockECRAPIRecorder) PutLifecyclePolicy(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "PutLifecyclePolicy", arg0) } -// PutLifecyclePolicyRequest mocks base method -func (m *MockECRAPI) PutLifecyclePolicyRequest(arg0 *ecr.PutLifecyclePolicyInput) (*request.Request, *ecr.PutLifecyclePolicyOutput) { - ret := m.ctrl.Call(m, "PutLifecyclePolicyRequest", arg0) +func (_m *MockECRAPI) PutLifecyclePolicyRequest(_param0 *ecr.PutLifecyclePolicyInput) (*request.Request, *ecr.PutLifecyclePolicyOutput) { + ret := _m.ctrl.Call(_m, "PutLifecyclePolicyRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.PutLifecyclePolicyOutput) return ret0, ret1 } -// PutLifecyclePolicyRequest indicates an expected call of PutLifecyclePolicyRequest -func (mr *MockECRAPIMockRecorder) PutLifecyclePolicyRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutLifecyclePolicyRequest", reflect.TypeOf((*MockECRAPI)(nil).PutLifecyclePolicyRequest), arg0) +func (_mr *_MockECRAPIRecorder) PutLifecyclePolicyRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "PutLifecyclePolicyRequest", arg0) } -// PutLifecyclePolicyWithContext mocks base method -func (m *MockECRAPI) PutLifecyclePolicyWithContext(arg0 aws.Context, arg1 *ecr.PutLifecyclePolicyInput, arg2 ...request.Option) (*ecr.PutLifecyclePolicyOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) PutLifecyclePolicyWithContext(_param0 context.Context, _param1 *ecr.PutLifecyclePolicyInput, _param2 ...request.Option) (*ecr.PutLifecyclePolicyOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "PutLifecyclePolicyWithContext", varargs...) + ret := _m.ctrl.Call(_m, "PutLifecyclePolicyWithContext", _s...) ret0, _ := ret[0].(*ecr.PutLifecyclePolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// PutLifecyclePolicyWithContext indicates an expected call of PutLifecyclePolicyWithContext -func (mr *MockECRAPIMockRecorder) PutLifecyclePolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "PutLifecyclePolicyWithContext", reflect.TypeOf((*MockECRAPI)(nil).PutLifecyclePolicyWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) PutLifecyclePolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "PutLifecyclePolicyWithContext", _s...) } -// SetRepositoryPolicy mocks base method -func (m *MockECRAPI) SetRepositoryPolicy(arg0 *ecr.SetRepositoryPolicyInput) (*ecr.SetRepositoryPolicyOutput, error) { - ret := m.ctrl.Call(m, "SetRepositoryPolicy", arg0) +func (_m *MockECRAPI) SetRepositoryPolicy(_param0 *ecr.SetRepositoryPolicyInput) (*ecr.SetRepositoryPolicyOutput, error) { + ret := _m.ctrl.Call(_m, "SetRepositoryPolicy", _param0) ret0, _ := ret[0].(*ecr.SetRepositoryPolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// SetRepositoryPolicy indicates an expected call of SetRepositoryPolicy -func (mr *MockECRAPIMockRecorder) SetRepositoryPolicy(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetRepositoryPolicy", reflect.TypeOf((*MockECRAPI)(nil).SetRepositoryPolicy), arg0) +func (_mr *_MockECRAPIRecorder) SetRepositoryPolicy(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "SetRepositoryPolicy", arg0) } -// SetRepositoryPolicyRequest mocks base method -func (m *MockECRAPI) SetRepositoryPolicyRequest(arg0 *ecr.SetRepositoryPolicyInput) (*request.Request, *ecr.SetRepositoryPolicyOutput) { - ret := m.ctrl.Call(m, "SetRepositoryPolicyRequest", arg0) +func (_m *MockECRAPI) SetRepositoryPolicyRequest(_param0 *ecr.SetRepositoryPolicyInput) (*request.Request, *ecr.SetRepositoryPolicyOutput) { + ret := _m.ctrl.Call(_m, "SetRepositoryPolicyRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.SetRepositoryPolicyOutput) return ret0, ret1 } -// SetRepositoryPolicyRequest indicates an expected call of SetRepositoryPolicyRequest -func (mr *MockECRAPIMockRecorder) SetRepositoryPolicyRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetRepositoryPolicyRequest", reflect.TypeOf((*MockECRAPI)(nil).SetRepositoryPolicyRequest), arg0) +func (_mr *_MockECRAPIRecorder) SetRepositoryPolicyRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "SetRepositoryPolicyRequest", arg0) } -// SetRepositoryPolicyWithContext mocks base method -func (m *MockECRAPI) SetRepositoryPolicyWithContext(arg0 aws.Context, arg1 *ecr.SetRepositoryPolicyInput, arg2 ...request.Option) (*ecr.SetRepositoryPolicyOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) SetRepositoryPolicyWithContext(_param0 context.Context, _param1 *ecr.SetRepositoryPolicyInput, _param2 ...request.Option) (*ecr.SetRepositoryPolicyOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "SetRepositoryPolicyWithContext", varargs...) + ret := _m.ctrl.Call(_m, "SetRepositoryPolicyWithContext", _s...) ret0, _ := ret[0].(*ecr.SetRepositoryPolicyOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// SetRepositoryPolicyWithContext indicates an expected call of SetRepositoryPolicyWithContext -func (mr *MockECRAPIMockRecorder) SetRepositoryPolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "SetRepositoryPolicyWithContext", reflect.TypeOf((*MockECRAPI)(nil).SetRepositoryPolicyWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) SetRepositoryPolicyWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "SetRepositoryPolicyWithContext", _s...) } -// StartLifecyclePolicyPreview mocks base method -func (m *MockECRAPI) StartLifecyclePolicyPreview(arg0 *ecr.StartLifecyclePolicyPreviewInput) (*ecr.StartLifecyclePolicyPreviewOutput, error) { - ret := m.ctrl.Call(m, "StartLifecyclePolicyPreview", arg0) +func (_m *MockECRAPI) StartLifecyclePolicyPreview(_param0 *ecr.StartLifecyclePolicyPreviewInput) (*ecr.StartLifecyclePolicyPreviewOutput, error) { + ret := _m.ctrl.Call(_m, "StartLifecyclePolicyPreview", _param0) ret0, _ := ret[0].(*ecr.StartLifecyclePolicyPreviewOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// StartLifecyclePolicyPreview indicates an expected call of StartLifecyclePolicyPreview -func (mr *MockECRAPIMockRecorder) StartLifecyclePolicyPreview(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StartLifecyclePolicyPreview", reflect.TypeOf((*MockECRAPI)(nil).StartLifecyclePolicyPreview), arg0) +func (_mr *_MockECRAPIRecorder) StartLifecyclePolicyPreview(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "StartLifecyclePolicyPreview", arg0) } -// StartLifecyclePolicyPreviewRequest mocks base method -func (m *MockECRAPI) StartLifecyclePolicyPreviewRequest(arg0 *ecr.StartLifecyclePolicyPreviewInput) (*request.Request, *ecr.StartLifecyclePolicyPreviewOutput) { - ret := m.ctrl.Call(m, "StartLifecyclePolicyPreviewRequest", arg0) +func (_m *MockECRAPI) StartLifecyclePolicyPreviewRequest(_param0 *ecr.StartLifecyclePolicyPreviewInput) (*request.Request, *ecr.StartLifecyclePolicyPreviewOutput) { + ret := _m.ctrl.Call(_m, "StartLifecyclePolicyPreviewRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.StartLifecyclePolicyPreviewOutput) return ret0, ret1 } -// StartLifecyclePolicyPreviewRequest indicates an expected call of StartLifecyclePolicyPreviewRequest -func (mr *MockECRAPIMockRecorder) StartLifecyclePolicyPreviewRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StartLifecyclePolicyPreviewRequest", reflect.TypeOf((*MockECRAPI)(nil).StartLifecyclePolicyPreviewRequest), arg0) +func (_mr *_MockECRAPIRecorder) StartLifecyclePolicyPreviewRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "StartLifecyclePolicyPreviewRequest", arg0) } -// StartLifecyclePolicyPreviewWithContext mocks base method -func (m *MockECRAPI) StartLifecyclePolicyPreviewWithContext(arg0 aws.Context, arg1 *ecr.StartLifecyclePolicyPreviewInput, arg2 ...request.Option) (*ecr.StartLifecyclePolicyPreviewOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) StartLifecyclePolicyPreviewWithContext(_param0 context.Context, _param1 *ecr.StartLifecyclePolicyPreviewInput, _param2 ...request.Option) (*ecr.StartLifecyclePolicyPreviewOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "StartLifecyclePolicyPreviewWithContext", varargs...) + ret := _m.ctrl.Call(_m, "StartLifecyclePolicyPreviewWithContext", _s...) ret0, _ := ret[0].(*ecr.StartLifecyclePolicyPreviewOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// StartLifecyclePolicyPreviewWithContext indicates an expected call of StartLifecyclePolicyPreviewWithContext -func (mr *MockECRAPIMockRecorder) StartLifecyclePolicyPreviewWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "StartLifecyclePolicyPreviewWithContext", reflect.TypeOf((*MockECRAPI)(nil).StartLifecyclePolicyPreviewWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) StartLifecyclePolicyPreviewWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "StartLifecyclePolicyPreviewWithContext", _s...) +} + +func (_m *MockECRAPI) TagResource(_param0 *ecr.TagResourceInput) (*ecr.TagResourceOutput, error) { + ret := _m.ctrl.Call(_m, "TagResource", _param0) + ret0, _ := ret[0].(*ecr.TagResourceOutput) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) TagResource(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "TagResource", arg0) +} + +func (_m *MockECRAPI) TagResourceRequest(_param0 *ecr.TagResourceInput) (*request.Request, *ecr.TagResourceOutput) { + ret := _m.ctrl.Call(_m, "TagResourceRequest", _param0) + ret0, _ := ret[0].(*request.Request) + ret1, _ := ret[1].(*ecr.TagResourceOutput) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) TagResourceRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "TagResourceRequest", arg0) +} + +func (_m *MockECRAPI) TagResourceWithContext(_param0 context.Context, _param1 *ecr.TagResourceInput, _param2 ...request.Option) (*ecr.TagResourceOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) + } + ret := _m.ctrl.Call(_m, "TagResourceWithContext", _s...) + ret0, _ := ret[0].(*ecr.TagResourceOutput) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) TagResourceWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "TagResourceWithContext", _s...) +} + +func (_m *MockECRAPI) UntagResource(_param0 *ecr.UntagResourceInput) (*ecr.UntagResourceOutput, error) { + ret := _m.ctrl.Call(_m, "UntagResource", _param0) + ret0, _ := ret[0].(*ecr.UntagResourceOutput) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) UntagResource(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "UntagResource", arg0) +} + +func (_m *MockECRAPI) UntagResourceRequest(_param0 *ecr.UntagResourceInput) (*request.Request, *ecr.UntagResourceOutput) { + ret := _m.ctrl.Call(_m, "UntagResourceRequest", _param0) + ret0, _ := ret[0].(*request.Request) + ret1, _ := ret[1].(*ecr.UntagResourceOutput) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) UntagResourceRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "UntagResourceRequest", arg0) +} + +func (_m *MockECRAPI) UntagResourceWithContext(_param0 context.Context, _param1 *ecr.UntagResourceInput, _param2 ...request.Option) (*ecr.UntagResourceOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) + } + ret := _m.ctrl.Call(_m, "UntagResourceWithContext", _s...) + ret0, _ := ret[0].(*ecr.UntagResourceOutput) + ret1, _ := ret[1].(error) + return ret0, ret1 +} + +func (_mr *_MockECRAPIRecorder) UntagResourceWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "UntagResourceWithContext", _s...) } -// UploadLayerPart mocks base method -func (m *MockECRAPI) UploadLayerPart(arg0 *ecr.UploadLayerPartInput) (*ecr.UploadLayerPartOutput, error) { - ret := m.ctrl.Call(m, "UploadLayerPart", arg0) +func (_m *MockECRAPI) UploadLayerPart(_param0 *ecr.UploadLayerPartInput) (*ecr.UploadLayerPartOutput, error) { + ret := _m.ctrl.Call(_m, "UploadLayerPart", _param0) ret0, _ := ret[0].(*ecr.UploadLayerPartOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// UploadLayerPart indicates an expected call of UploadLayerPart -func (mr *MockECRAPIMockRecorder) UploadLayerPart(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UploadLayerPart", reflect.TypeOf((*MockECRAPI)(nil).UploadLayerPart), arg0) +func (_mr *_MockECRAPIRecorder) UploadLayerPart(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "UploadLayerPart", arg0) } -// UploadLayerPartRequest mocks base method -func (m *MockECRAPI) UploadLayerPartRequest(arg0 *ecr.UploadLayerPartInput) (*request.Request, *ecr.UploadLayerPartOutput) { - ret := m.ctrl.Call(m, "UploadLayerPartRequest", arg0) +func (_m *MockECRAPI) UploadLayerPartRequest(_param0 *ecr.UploadLayerPartInput) (*request.Request, *ecr.UploadLayerPartOutput) { + ret := _m.ctrl.Call(_m, "UploadLayerPartRequest", _param0) ret0, _ := ret[0].(*request.Request) ret1, _ := ret[1].(*ecr.UploadLayerPartOutput) return ret0, ret1 } -// UploadLayerPartRequest indicates an expected call of UploadLayerPartRequest -func (mr *MockECRAPIMockRecorder) UploadLayerPartRequest(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UploadLayerPartRequest", reflect.TypeOf((*MockECRAPI)(nil).UploadLayerPartRequest), arg0) +func (_mr *_MockECRAPIRecorder) UploadLayerPartRequest(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "UploadLayerPartRequest", arg0) } -// UploadLayerPartWithContext mocks base method -func (m *MockECRAPI) UploadLayerPartWithContext(arg0 aws.Context, arg1 *ecr.UploadLayerPartInput, arg2 ...request.Option) (*ecr.UploadLayerPartOutput, error) { - varargs := []interface{}{arg0, arg1} - for _, a := range arg2 { - varargs = append(varargs, a) +func (_m *MockECRAPI) UploadLayerPartWithContext(_param0 context.Context, _param1 *ecr.UploadLayerPartInput, _param2 ...request.Option) (*ecr.UploadLayerPartOutput, error) { + _s := []interface{}{_param0, _param1} + for _, _x := range _param2 { + _s = append(_s, _x) } - ret := m.ctrl.Call(m, "UploadLayerPartWithContext", varargs...) + ret := _m.ctrl.Call(_m, "UploadLayerPartWithContext", _s...) ret0, _ := ret[0].(*ecr.UploadLayerPartOutput) ret1, _ := ret[1].(error) return ret0, ret1 } -// UploadLayerPartWithContext indicates an expected call of UploadLayerPartWithContext -func (mr *MockECRAPIMockRecorder) UploadLayerPartWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { - varargs := append([]interface{}{arg0, arg1}, arg2...) - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UploadLayerPartWithContext", reflect.TypeOf((*MockECRAPI)(nil).UploadLayerPartWithContext), varargs...) +func (_mr *_MockECRAPIRecorder) UploadLayerPartWithContext(arg0, arg1 interface{}, arg2 ...interface{}) *gomock.Call { + _s := append([]interface{}{arg0, arg1}, arg2...) + return _mr.mock.ctrl.RecordCall(_mr.mock, "UploadLayerPartWithContext", _s...) } diff --git a/ecr-login/cache/mocks/cache_mocks.go b/ecr-login/cache/mocks/cache_mocks.go index 62769990..9b542378 100644 --- a/ecr-login/cache/mocks/cache_mocks.go +++ b/ecr-login/cache/mocks/cache_mocks.go @@ -11,82 +11,69 @@ // express or implied. See the License for the specific language governing // permissions and limitations under the License. -// Code generated by MockGen. DO NOT EDIT. +// Automatically generated by MockGen. DO NOT EDIT! // Source: github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache (interfaces: CredentialsCache) -// Package mock_cache is a generated GoMock package. package mock_cache import ( - reflect "reflect" - cache "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/cache" gomock "github.com/golang/mock/gomock" ) -// MockCredentialsCache is a mock of CredentialsCache interface +// Mock of CredentialsCache interface type MockCredentialsCache struct { ctrl *gomock.Controller - recorder *MockCredentialsCacheMockRecorder + recorder *_MockCredentialsCacheRecorder } -// MockCredentialsCacheMockRecorder is the mock recorder for MockCredentialsCache -type MockCredentialsCacheMockRecorder struct { +// Recorder for MockCredentialsCache (not exported) +type _MockCredentialsCacheRecorder struct { mock *MockCredentialsCache } -// NewMockCredentialsCache creates a new mock instance func NewMockCredentialsCache(ctrl *gomock.Controller) *MockCredentialsCache { mock := &MockCredentialsCache{ctrl: ctrl} - mock.recorder = &MockCredentialsCacheMockRecorder{mock} + mock.recorder = &_MockCredentialsCacheRecorder{mock} return mock } -// EXPECT returns an object that allows the caller to indicate expected use -func (m *MockCredentialsCache) EXPECT() *MockCredentialsCacheMockRecorder { - return m.recorder +func (_m *MockCredentialsCache) EXPECT() *_MockCredentialsCacheRecorder { + return _m.recorder } -// Clear mocks base method -func (m *MockCredentialsCache) Clear() { - m.ctrl.Call(m, "Clear") +func (_m *MockCredentialsCache) Clear() { + _m.ctrl.Call(_m, "Clear") } -// Clear indicates an expected call of Clear -func (mr *MockCredentialsCacheMockRecorder) Clear() *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Clear", reflect.TypeOf((*MockCredentialsCache)(nil).Clear)) +func (_mr *_MockCredentialsCacheRecorder) Clear() *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "Clear") } -// Get mocks base method -func (m *MockCredentialsCache) Get(arg0 string) *cache.AuthEntry { - ret := m.ctrl.Call(m, "Get", arg0) +func (_m *MockCredentialsCache) Get(_param0 string) *cache.AuthEntry { + ret := _m.ctrl.Call(_m, "Get", _param0) ret0, _ := ret[0].(*cache.AuthEntry) return ret0 } -// Get indicates an expected call of Get -func (mr *MockCredentialsCacheMockRecorder) Get(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Get", reflect.TypeOf((*MockCredentialsCache)(nil).Get), arg0) +func (_mr *_MockCredentialsCacheRecorder) Get(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "Get", arg0) } -// List mocks base method -func (m *MockCredentialsCache) List() []*cache.AuthEntry { - ret := m.ctrl.Call(m, "List") +func (_m *MockCredentialsCache) List() []*cache.AuthEntry { + ret := _m.ctrl.Call(_m, "List") ret0, _ := ret[0].([]*cache.AuthEntry) return ret0 } -// List indicates an expected call of List -func (mr *MockCredentialsCacheMockRecorder) List() *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "List", reflect.TypeOf((*MockCredentialsCache)(nil).List)) +func (_mr *_MockCredentialsCacheRecorder) List() *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "List") } -// Set mocks base method -func (m *MockCredentialsCache) Set(arg0 string, arg1 *cache.AuthEntry) { - m.ctrl.Call(m, "Set", arg0, arg1) +func (_m *MockCredentialsCache) Set(_param0 string, _param1 *cache.AuthEntry) { + _m.ctrl.Call(_m, "Set", _param0, _param1) } -// Set indicates an expected call of Set -func (mr *MockCredentialsCacheMockRecorder) Set(arg0, arg1 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Set", reflect.TypeOf((*MockCredentialsCache)(nil).Set), arg0, arg1) +func (_mr *_MockCredentialsCacheRecorder) Set(arg0, arg1 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "Set", arg0, arg1) } diff --git a/ecr-login/mocks/ecr_mocks.go b/ecr-login/mocks/ecr_mocks.go index adf9ebaf..c440199f 100644 --- a/ecr-login/mocks/ecr_mocks.go +++ b/ecr-login/mocks/ecr_mocks.go @@ -11,163 +11,140 @@ // express or implied. See the License for the specific language governing // permissions and limitations under the License. -// Code generated by MockGen. DO NOT EDIT. +// Automatically generated by MockGen. DO NOT EDIT! // Source: github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api (interfaces: ClientFactory,Client) -// Package mock_api is a generated GoMock package. package mock_api import ( - reflect "reflect" - aws "github.com/aws/aws-sdk-go/aws" session "github.com/aws/aws-sdk-go/aws/session" api "github.com/awslabs/amazon-ecr-credential-helper/ecr-login/api" gomock "github.com/golang/mock/gomock" ) -// MockClientFactory is a mock of ClientFactory interface +// Mock of ClientFactory interface type MockClientFactory struct { ctrl *gomock.Controller - recorder *MockClientFactoryMockRecorder + recorder *_MockClientFactoryRecorder } -// MockClientFactoryMockRecorder is the mock recorder for MockClientFactory -type MockClientFactoryMockRecorder struct { +// Recorder for MockClientFactory (not exported) +type _MockClientFactoryRecorder struct { mock *MockClientFactory } -// NewMockClientFactory creates a new mock instance func NewMockClientFactory(ctrl *gomock.Controller) *MockClientFactory { mock := &MockClientFactory{ctrl: ctrl} - mock.recorder = &MockClientFactoryMockRecorder{mock} + mock.recorder = &_MockClientFactoryRecorder{mock} return mock } -// EXPECT returns an object that allows the caller to indicate expected use -func (m *MockClientFactory) EXPECT() *MockClientFactoryMockRecorder { - return m.recorder +func (_m *MockClientFactory) EXPECT() *_MockClientFactoryRecorder { + return _m.recorder } -// NewClient mocks base method -func (m *MockClientFactory) NewClient(arg0 *session.Session, arg1 *aws.Config) api.Client { - ret := m.ctrl.Call(m, "NewClient", arg0, arg1) +func (_m *MockClientFactory) NewClient(_param0 *session.Session, _param1 *aws.Config) api.Client { + ret := _m.ctrl.Call(_m, "NewClient", _param0, _param1) ret0, _ := ret[0].(api.Client) return ret0 } -// NewClient indicates an expected call of NewClient -func (mr *MockClientFactoryMockRecorder) NewClient(arg0, arg1 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewClient", reflect.TypeOf((*MockClientFactory)(nil).NewClient), arg0, arg1) +func (_mr *_MockClientFactoryRecorder) NewClient(arg0, arg1 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "NewClient", arg0, arg1) } -// NewClientFromRegion mocks base method -func (m *MockClientFactory) NewClientFromRegion(arg0 string) api.Client { - ret := m.ctrl.Call(m, "NewClientFromRegion", arg0) +func (_m *MockClientFactory) NewClientFromRegion(_param0 string) api.Client { + ret := _m.ctrl.Call(_m, "NewClientFromRegion", _param0) ret0, _ := ret[0].(api.Client) return ret0 } -// NewClientFromRegion indicates an expected call of NewClientFromRegion -func (mr *MockClientFactoryMockRecorder) NewClientFromRegion(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewClientFromRegion", reflect.TypeOf((*MockClientFactory)(nil).NewClientFromRegion), arg0) +func (_mr *_MockClientFactoryRecorder) NewClientFromRegion(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "NewClientFromRegion", arg0) } -// NewClientWithDefaults mocks base method -func (m *MockClientFactory) NewClientWithDefaults() api.Client { - ret := m.ctrl.Call(m, "NewClientWithDefaults") +func (_m *MockClientFactory) NewClientWithDefaults() api.Client { + ret := _m.ctrl.Call(_m, "NewClientWithDefaults") ret0, _ := ret[0].(api.Client) return ret0 } -// NewClientWithDefaults indicates an expected call of NewClientWithDefaults -func (mr *MockClientFactoryMockRecorder) NewClientWithDefaults() *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewClientWithDefaults", reflect.TypeOf((*MockClientFactory)(nil).NewClientWithDefaults)) +func (_mr *_MockClientFactoryRecorder) NewClientWithDefaults() *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "NewClientWithDefaults") } -// NewClientWithFipsEndpoint mocks base method -func (m *MockClientFactory) NewClientWithFipsEndpoint(arg0 string) (api.Client, error) { - ret := m.ctrl.Call(m, "NewClientWithFipsEndpoint", arg0) +func (_m *MockClientFactory) NewClientWithFipsEndpoint(_param0 string) (api.Client, error) { + ret := _m.ctrl.Call(_m, "NewClientWithFipsEndpoint", _param0) ret0, _ := ret[0].(api.Client) ret1, _ := ret[1].(error) return ret0, ret1 } -// NewClientWithFipsEndpoint indicates an expected call of NewClientWithFipsEndpoint -func (mr *MockClientFactoryMockRecorder) NewClientWithFipsEndpoint(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewClientWithFipsEndpoint", reflect.TypeOf((*MockClientFactory)(nil).NewClientWithFipsEndpoint), arg0) +func (_mr *_MockClientFactoryRecorder) NewClientWithFipsEndpoint(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "NewClientWithFipsEndpoint", arg0) } -// NewClientWithOptions mocks base method -func (m *MockClientFactory) NewClientWithOptions(arg0 api.Options) api.Client { - ret := m.ctrl.Call(m, "NewClientWithOptions", arg0) +func (_m *MockClientFactory) NewClientWithOptions(_param0 api.Options) api.Client { + ret := _m.ctrl.Call(_m, "NewClientWithOptions", _param0) ret0, _ := ret[0].(api.Client) return ret0 } -// NewClientWithOptions indicates an expected call of NewClientWithOptions -func (mr *MockClientFactoryMockRecorder) NewClientWithOptions(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewClientWithOptions", reflect.TypeOf((*MockClientFactory)(nil).NewClientWithOptions), arg0) +func (_mr *_MockClientFactoryRecorder) NewClientWithOptions(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "NewClientWithOptions", arg0) } -// MockClient is a mock of Client interface +// Mock of Client interface type MockClient struct { ctrl *gomock.Controller - recorder *MockClientMockRecorder + recorder *_MockClientRecorder } -// MockClientMockRecorder is the mock recorder for MockClient -type MockClientMockRecorder struct { +// Recorder for MockClient (not exported) +type _MockClientRecorder struct { mock *MockClient } -// NewMockClient creates a new mock instance func NewMockClient(ctrl *gomock.Controller) *MockClient { mock := &MockClient{ctrl: ctrl} - mock.recorder = &MockClientMockRecorder{mock} + mock.recorder = &_MockClientRecorder{mock} return mock } -// EXPECT returns an object that allows the caller to indicate expected use -func (m *MockClient) EXPECT() *MockClientMockRecorder { - return m.recorder +func (_m *MockClient) EXPECT() *_MockClientRecorder { + return _m.recorder } -// GetCredentials mocks base method -func (m *MockClient) GetCredentials(arg0 string) (*api.Auth, error) { - ret := m.ctrl.Call(m, "GetCredentials", arg0) +func (_m *MockClient) GetCredentials(_param0 string) (*api.Auth, error) { + ret := _m.ctrl.Call(_m, "GetCredentials", _param0) ret0, _ := ret[0].(*api.Auth) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetCredentials indicates an expected call of GetCredentials -func (mr *MockClientMockRecorder) GetCredentials(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetCredentials", reflect.TypeOf((*MockClient)(nil).GetCredentials), arg0) +func (_mr *_MockClientRecorder) GetCredentials(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetCredentials", arg0) } -// GetCredentialsByRegistryID mocks base method -func (m *MockClient) GetCredentialsByRegistryID(arg0 string) (*api.Auth, error) { - ret := m.ctrl.Call(m, "GetCredentialsByRegistryID", arg0) +func (_m *MockClient) GetCredentialsByRegistryID(_param0 string) (*api.Auth, error) { + ret := _m.ctrl.Call(_m, "GetCredentialsByRegistryID", _param0) ret0, _ := ret[0].(*api.Auth) ret1, _ := ret[1].(error) return ret0, ret1 } -// GetCredentialsByRegistryID indicates an expected call of GetCredentialsByRegistryID -func (mr *MockClientMockRecorder) GetCredentialsByRegistryID(arg0 interface{}) *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetCredentialsByRegistryID", reflect.TypeOf((*MockClient)(nil).GetCredentialsByRegistryID), arg0) +func (_mr *_MockClientRecorder) GetCredentialsByRegistryID(arg0 interface{}) *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "GetCredentialsByRegistryID", arg0) } -// ListCredentials mocks base method -func (m *MockClient) ListCredentials() ([]*api.Auth, error) { - ret := m.ctrl.Call(m, "ListCredentials") +func (_m *MockClient) ListCredentials() ([]*api.Auth, error) { + ret := _m.ctrl.Call(_m, "ListCredentials") ret0, _ := ret[0].([]*api.Auth) ret1, _ := ret[1].(error) return ret0, ret1 } -// ListCredentials indicates an expected call of ListCredentials -func (mr *MockClientMockRecorder) ListCredentials() *gomock.Call { - return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ListCredentials", reflect.TypeOf((*MockClient)(nil).ListCredentials)) +func (_mr *_MockClientRecorder) ListCredentials() *gomock.Call { + return _mr.mock.ctrl.RecordCall(_mr.mock, "ListCredentials") } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go index b6432f1a..645df245 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/awsutil/string_value.go @@ -23,28 +23,27 @@ func stringValue(v reflect.Value, indent int, buf *bytes.Buffer) { case reflect.Struct: buf.WriteString("{\n") - names := []string{} for i := 0; i < v.Type().NumField(); i++ { - name := v.Type().Field(i).Name - f := v.Field(i) - if name[0:1] == strings.ToLower(name[0:1]) { + ft := v.Type().Field(i) + fv := v.Field(i) + + if ft.Name[0:1] == strings.ToLower(ft.Name[0:1]) { continue // ignore unexported fields } - if (f.Kind() == reflect.Ptr || f.Kind() == reflect.Slice) && f.IsNil() { + if (fv.Kind() == reflect.Ptr || fv.Kind() == reflect.Slice) && fv.IsNil() { continue // ignore unset fields } - names = append(names, name) - } - for i, n := range names { - val := v.FieldByName(n) buf.WriteString(strings.Repeat(" ", indent+2)) - buf.WriteString(n + ": ") - stringValue(val, indent+2, buf) + buf.WriteString(ft.Name + ": ") - if i < len(names)-1 { - buf.WriteString(",\n") + if tag := ft.Tag.Get("sensitive"); tag == "true" { + buf.WriteString("") + } else { + stringValue(fv, indent+2, buf) } + + buf.WriteString(",\n") } buf.WriteString("\n" + strings.Repeat(" ", indent) + "}") diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/client/client.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/client/client.go index 212fe25e..70960538 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/client/client.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/client/client.go @@ -18,7 +18,7 @@ type Config struct { // States that the signing name did not come from a modeled source but // was derived based on other data. Used by service client constructors - // to determine if the signin name can be overriden based on metadata the + // to determine if the signin name can be overridden based on metadata the // service has. SigningNameDerived bool } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/config.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/config.go index 58c89fa0..10634d17 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/config.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/config.go @@ -45,8 +45,8 @@ type Config struct { // that overrides the default generated endpoint for a client. Set this // to `""` to use the default generated endpoint. // - // @note You must still provide a `Region` value when specifying an - // endpoint for a client. + // Note: You must still provide a `Region` value when specifying an + // endpoint for a client. Endpoint *string // The resolver to use for looking up endpoints for AWS service clients @@ -65,8 +65,8 @@ type Config struct { // noted. A full list of regions is found in the "Regions and Endpoints" // document. // - // @see http://docs.aws.amazon.com/general/latest/gr/rande.html - // AWS Regions and Endpoints + // See http://docs.aws.amazon.com/general/latest/gr/rande.html for AWS + // Regions and Endpoints. Region *string // Set this to `true` to disable SSL when sending requests. Defaults @@ -120,9 +120,10 @@ type Config struct { // will use virtual hosted bucket addressing when possible // (`http://BUCKET.s3.amazonaws.com/KEY`). // - // @note This configuration option is specific to the Amazon S3 service. - // @see http://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html - // Amazon S3: Virtual Hosting of Buckets + // Note: This configuration option is specific to the Amazon S3 service. + // + // See http://docs.aws.amazon.com/AmazonS3/latest/dev/VirtualHosting.html + // for Amazon S3: Virtual Hosting of Buckets S3ForcePathStyle *bool // Set this to `true` to disable the SDK adding the `Expect: 100-Continue` @@ -223,6 +224,28 @@ type Config struct { // Key: aws.String("//foo//bar//moo"), // }) DisableRestProtocolURICleaning *bool + + // EnableEndpointDiscovery will allow for endpoint discovery on operations that + // have the definition in its model. By default, endpoint discovery is off. + // + // Example: + // sess := session.Must(session.NewSession(&aws.Config{ + // EnableEndpointDiscovery: aws.Bool(true), + // })) + // + // svc := s3.New(sess) + // out, err := svc.GetObject(&s3.GetObjectInput { + // Bucket: aws.String("bucketname"), + // Key: aws.String("/foo/bar/moo"), + // }) + EnableEndpointDiscovery *bool + + // DisableEndpointHostPrefix will disable the SDK's behavior of prefixing + // request endpoint hosts with modeled information. + // + // Disabling this feature is useful when you want to use local endpoints + // for testing that do not support the modeled host prefix pattern. + DisableEndpointHostPrefix *bool } // NewConfig returns a new Config pointer that can be chained with builder @@ -377,6 +400,19 @@ func (c *Config) WithSleepDelay(fn func(time.Duration)) *Config { return c } +// WithEndpointDiscovery will set whether or not to use endpoint discovery. +func (c *Config) WithEndpointDiscovery(t bool) *Config { + c.EnableEndpointDiscovery = &t + return c +} + +// WithDisableEndpointHostPrefix will set whether or not to use modeled host prefix +// when making requests. +func (c *Config) WithDisableEndpointHostPrefix(t bool) *Config { + c.DisableEndpointHostPrefix = &t + return c +} + // MergeIn merges the passed in configs into the existing config object. func (c *Config) MergeIn(cfgs ...*Config) { for _, other := range cfgs { @@ -476,6 +512,14 @@ func mergeInConfig(dst *Config, other *Config) { if other.EnforceShouldRetryCheck != nil { dst.EnforceShouldRetryCheck = other.EnforceShouldRetryCheck } + + if other.EnableEndpointDiscovery != nil { + dst.EnableEndpointDiscovery = other.EnableEndpointDiscovery + } + + if other.DisableEndpointHostPrefix != nil { + dst.DisableEndpointHostPrefix = other.DisableEndpointHostPrefix + } } // Copy will return a shallow copy of the Config object. If any additional diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go similarity index 58% rename from ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context.go rename to ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go index 79f42685..2866f9a7 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_5.go @@ -1,8 +1,8 @@ +// +build !go1.9 + package aws -import ( - "time" -) +import "time" // Context is an copy of the Go v1.7 stdlib's context.Context interface. // It is represented as a SDK interface to enable you to use the "WithContext" @@ -35,37 +35,3 @@ type Context interface { // functions. Value(key interface{}) interface{} } - -// BackgroundContext returns a context that will never be canceled, has no -// values, and no deadline. This context is used by the SDK to provide -// backwards compatibility with non-context API operations and functionality. -// -// Go 1.6 and before: -// This context function is equivalent to context.Background in the Go stdlib. -// -// Go 1.7 and later: -// The context returned will be the value returned by context.Background() -// -// See https://golang.org/pkg/context for more information on Contexts. -func BackgroundContext() Context { - return backgroundCtx -} - -// SleepWithContext will wait for the timer duration to expire, or the context -// is canceled. Which ever happens first. If the context is canceled the Context's -// error will be returned. -// -// Expects Context to always return a non-nil error if the Done channel is closed. -func SleepWithContext(ctx Context, dur time.Duration) error { - t := time.NewTimer(dur) - defer t.Stop() - - select { - case <-t.C: - break - case <-ctx.Done(): - return ctx.Err() - } - - return nil -} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_7.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_7.go deleted file mode 100644 index 064f75c9..00000000 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_7.go +++ /dev/null @@ -1,9 +0,0 @@ -// +build go1.7 - -package aws - -import "context" - -var ( - backgroundCtx = context.Background() -) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go new file mode 100644 index 00000000..3718b26e --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_9.go @@ -0,0 +1,11 @@ +// +build go1.9 + +package aws + +import "context" + +// Context is an alias of the Go stdlib's context.Context interface. +// It can be used within the SDK's API operation "WithContext" methods. +// +// See https://golang.org/pkg/context on how to use contexts. +type Context = context.Context diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_6.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go similarity index 59% rename from ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_6.go rename to ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go index 8fdda530..66c5945d 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_1_6.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_5.go @@ -39,3 +39,18 @@ func (e *emptyCtx) String() string { var ( backgroundCtx = new(emptyCtx) ) + +// BackgroundContext returns a context that will never be canceled, has no +// values, and no deadline. This context is used by the SDK to provide +// backwards compatibility with non-context API operations and functionality. +// +// Go 1.6 and before: +// This context function is equivalent to context.Background in the Go stdlib. +// +// Go 1.7 and later: +// The context returned will be the value returned by context.Background() +// +// See https://golang.org/pkg/context for more information on Contexts. +func BackgroundContext() Context { + return backgroundCtx +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go new file mode 100644 index 00000000..9c29f29a --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_background_1_7.go @@ -0,0 +1,20 @@ +// +build go1.7 + +package aws + +import "context" + +// BackgroundContext returns a context that will never be canceled, has no +// values, and no deadline. This context is used by the SDK to provide +// backwards compatibility with non-context API operations and functionality. +// +// Go 1.6 and before: +// This context function is equivalent to context.Background in the Go stdlib. +// +// Go 1.7 and later: +// The context returned will be the value returned by context.Background() +// +// See https://golang.org/pkg/context for more information on Contexts. +func BackgroundContext() Context { + return context.Background() +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go new file mode 100644 index 00000000..304fd156 --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/context_sleep.go @@ -0,0 +1,24 @@ +package aws + +import ( + "time" +) + +// SleepWithContext will wait for the timer duration to expire, or the context +// is canceled. Which ever happens first. If the context is canceled the Context's +// error will be returned. +// +// Expects Context to always return a non-nil error if the Done channel is closed. +func SleepWithContext(ctx Context, dur time.Duration) error { + t := time.NewTimer(dur) + defer t.Stop() + + select { + case <-t.C: + break + case <-ctx.Done(): + return ctx.Err() + } + + return nil +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go index cfcddf3d..f8853d78 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/handlers.go @@ -72,9 +72,9 @@ var ValidateReqSigHandler = request.NamedHandler{ signedTime = r.LastSignedAt } - // 10 minutes to allow for some clock skew/delays in transmission. + // 5 minutes to allow for some clock skew/delays in transmission. // Would be improved with aws/aws-sdk-go#423 - if signedTime.Add(10 * time.Minute).After(time.Now()) { + if signedTime.Add(5 * time.Minute).After(time.Now()) { return } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go index a15f496b..ab69c7a6 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/corehandlers/user_agent.go @@ -17,7 +17,7 @@ var SDKVersionUserAgentHandler = request.NamedHandler{ } const execEnvVar = `AWS_EXECUTION_ENV` -const execEnvUAKey = `exec_env` +const execEnvUAKey = `exec-env` // AddHostExecEnvUserAgentHander is a request handler appending the SDK's // execution environment to the user agent. diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go index f298d659..3ad1e798 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/chain_provider.go @@ -9,9 +9,7 @@ var ( // providers in the ChainProvider. // // This has been deprecated. For verbose error messaging set - // aws.Config.CredentialsChainVerboseErrors to true - // - // @readonly + // aws.Config.CredentialsChainVerboseErrors to true. ErrNoValidProvidersFoundInChain = awserr.New("NoCredentialProviders", `no valid providers in chain. Deprecated. For verbose messaging see aws.Config.CredentialsChainVerboseErrors`, diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go index a270844d..894bbc7f 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/credentials.go @@ -49,6 +49,8 @@ package credentials import ( + "fmt" + "github.com/aws/aws-sdk-go/aws/awserr" "sync" "time" ) @@ -64,8 +66,6 @@ import ( // Credentials: credentials.AnonymousCredentials, // }))) // // Access public S3 buckets. -// -// @readonly var AnonymousCredentials = NewStaticCredentials("", "", "") // A Value is the AWS credentials value for individual credential fields. @@ -99,6 +99,14 @@ type Provider interface { IsExpired() bool } +// An Expirer is an interface that Providers can implement to expose the expiration +// time, if known. If the Provider cannot accurately provide this info, +// it should not implement this interface. +type Expirer interface { + // The time at which the credentials are no longer valid + ExpiresAt() time.Time +} + // An ErrorProvider is a stub credentials provider that always returns an error // this is used by the SDK when construction a known provider is not possible // due to an error. @@ -165,6 +173,11 @@ func (e *Expiry) IsExpired() bool { return e.expiration.Before(curTime()) } +// ExpiresAt returns the expiration time of the credential +func (e *Expiry) ExpiresAt() time.Time { + return e.expiration +} + // A Credentials provides concurrency safe retrieval of AWS credentials Value. // Credentials will cache the credentials value until they expire. Once the value // expires the next Get will attempt to retrieve valid credentials. @@ -257,3 +270,23 @@ func (c *Credentials) IsExpired() bool { func (c *Credentials) isExpired() bool { return c.forceRefresh || c.provider.IsExpired() } + +// ExpiresAt provides access to the functionality of the Expirer interface of +// the underlying Provider, if it supports that interface. Otherwise, it returns +// an error. +func (c *Credentials) ExpiresAt() (time.Time, error) { + c.m.RLock() + defer c.m.RUnlock() + + expirer, ok := c.provider.(Expirer) + if !ok { + return time.Time{}, awserr.New("ProviderNotExpirer", + fmt.Sprintf("provider %s does not support ExpiresAt()", c.creds.ProviderName), + nil) + } + if c.forceRefresh { + // set expiration time to the distant past + return time.Time{}, nil + } + return expirer.ExpiresAt(), nil +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go index c14231a1..54c5cf73 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/env_provider.go @@ -12,14 +12,10 @@ const EnvProviderName = "EnvProvider" var ( // ErrAccessKeyIDNotFound is returned when the AWS Access Key ID can't be // found in the process's environment. - // - // @readonly ErrAccessKeyIDNotFound = awserr.New("EnvAccessKeyNotFound", "AWS_ACCESS_KEY_ID or AWS_ACCESS_KEY not found in environment", nil) // ErrSecretAccessKeyNotFound is returned when the AWS Secret Access Key // can't be found in the process's environment. - // - // @readonly ErrSecretAccessKeyNotFound = awserr.New("EnvSecretNotFound", "AWS_SECRET_ACCESS_KEY or AWS_SECRET_KEY not found in environment", nil) ) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go new file mode 100644 index 00000000..1980c8c1 --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/processcreds/provider.go @@ -0,0 +1,425 @@ +/* +Package processcreds is a credential Provider to retrieve `credential_process` +credentials. + +WARNING: The following describes a method of sourcing credentials from an external +process. This can potentially be dangerous, so proceed with caution. Other +credential providers should be preferred if at all possible. If using this +option, you should make sure that the config file is as locked down as possible +using security best practices for your operating system. + +You can use credentials from a `credential_process` in a variety of ways. + +One way is to setup your shared config file, located in the default +location, with the `credential_process` key and the command you want to be +called. You also need to set the AWS_SDK_LOAD_CONFIG environment variable +(e.g., `export AWS_SDK_LOAD_CONFIG=1`) to use the shared config file. + + [default] + credential_process = /command/to/call + +Creating a new session will use the credential process to retrieve credentials. +NOTE: If there are credentials in the profile you are using, the credential +process will not be used. + + // Initialize a session to load credentials. + sess, _ := session.NewSession(&aws.Config{ + Region: aws.String("us-east-1")}, + ) + + // Create S3 service client to use the credentials. + svc := s3.New(sess) + +Another way to use the `credential_process` method is by using +`credentials.NewCredentials()` and providing a command to be executed to +retrieve credentials: + + // Create credentials using the ProcessProvider. + creds := processcreds.NewCredentials("/path/to/command") + + // Create service client value configured for credentials. + svc := s3.New(sess, &aws.Config{Credentials: creds}) + +You can set a non-default timeout for the `credential_process` with another +constructor, `credentials.NewCredentialsTimeout()`, providing the timeout. To +set a one minute timeout: + + // Create credentials using the ProcessProvider. + creds := processcreds.NewCredentialsTimeout( + "/path/to/command", + time.Duration(500) * time.Millisecond) + +If you need more control, you can set any configurable options in the +credentials using one or more option functions. For example, you can set a two +minute timeout, a credential duration of 60 minutes, and a maximum stdout +buffer size of 2k. + + creds := processcreds.NewCredentials( + "/path/to/command", + func(opt *ProcessProvider) { + opt.Timeout = time.Duration(2) * time.Minute + opt.Duration = time.Duration(60) * time.Minute + opt.MaxBufSize = 2048 + }) + +You can also use your own `exec.Cmd`: + + // Create an exec.Cmd + myCommand := exec.Command("/path/to/command") + + // Create credentials using your exec.Cmd and custom timeout + creds := processcreds.NewCredentialsCommand( + myCommand, + func(opt *processcreds.ProcessProvider) { + opt.Timeout = time.Duration(1) * time.Second + }) +*/ +package processcreds + +import ( + "bytes" + "encoding/json" + "fmt" + "io" + "io/ioutil" + "os" + "os/exec" + "runtime" + "strings" + "time" + + "github.com/aws/aws-sdk-go/aws/awserr" + "github.com/aws/aws-sdk-go/aws/credentials" +) + +const ( + // ProviderName is the name this credentials provider will label any + // returned credentials Value with. + ProviderName = `ProcessProvider` + + // ErrCodeProcessProviderParse error parsing process output + ErrCodeProcessProviderParse = "ProcessProviderParseError" + + // ErrCodeProcessProviderVersion version error in output + ErrCodeProcessProviderVersion = "ProcessProviderVersionError" + + // ErrCodeProcessProviderRequired required attribute missing in output + ErrCodeProcessProviderRequired = "ProcessProviderRequiredError" + + // ErrCodeProcessProviderExecution execution of command failed + ErrCodeProcessProviderExecution = "ProcessProviderExecutionError" + + // errMsgProcessProviderTimeout process took longer than allowed + errMsgProcessProviderTimeout = "credential process timed out" + + // errMsgProcessProviderProcess process error + errMsgProcessProviderProcess = "error in credential_process" + + // errMsgProcessProviderParse problem parsing output + errMsgProcessProviderParse = "parse failed of credential_process output" + + // errMsgProcessProviderVersion version error in output + errMsgProcessProviderVersion = "wrong version in process output (not 1)" + + // errMsgProcessProviderMissKey missing access key id in output + errMsgProcessProviderMissKey = "missing AccessKeyId in process output" + + // errMsgProcessProviderMissSecret missing secret acess key in output + errMsgProcessProviderMissSecret = "missing SecretAccessKey in process output" + + // errMsgProcessProviderPrepareCmd prepare of command failed + errMsgProcessProviderPrepareCmd = "failed to prepare command" + + // errMsgProcessProviderEmptyCmd command must not be empty + errMsgProcessProviderEmptyCmd = "command must not be empty" + + // errMsgProcessProviderPipe failed to initialize pipe + errMsgProcessProviderPipe = "failed to initialize pipe" + + // DefaultDuration is the default amount of time in minutes that the + // credentials will be valid for. + DefaultDuration = time.Duration(15) * time.Minute + + // DefaultBufSize limits buffer size from growing to an enormous + // amount due to a faulty process. + DefaultBufSize = 1024 + + // DefaultTimeout default limit on time a process can run. + DefaultTimeout = time.Duration(1) * time.Minute +) + +// ProcessProvider satisfies the credentials.Provider interface, and is a +// client to retrieve credentials from a process. +type ProcessProvider struct { + staticCreds bool + credentials.Expiry + originalCommand []string + + // Expiry duration of the credentials. Defaults to 15 minutes if not set. + Duration time.Duration + + // ExpiryWindow will allow the credentials to trigger refreshing prior to + // the credentials actually expiring. This is beneficial so race conditions + // with expiring credentials do not cause request to fail unexpectedly + // due to ExpiredTokenException exceptions. + // + // So a ExpiryWindow of 10s would cause calls to IsExpired() to return true + // 10 seconds before the credentials are actually expired. + // + // If ExpiryWindow is 0 or less it will be ignored. + ExpiryWindow time.Duration + + // A string representing an os command that should return a JSON with + // credential information. + command *exec.Cmd + + // MaxBufSize limits memory usage from growing to an enormous + // amount due to a faulty process. + MaxBufSize int + + // Timeout limits the time a process can run. + Timeout time.Duration +} + +// NewCredentials returns a pointer to a new Credentials object wrapping the +// ProcessProvider. The credentials will expire every 15 minutes by default. +func NewCredentials(command string, options ...func(*ProcessProvider)) *credentials.Credentials { + p := &ProcessProvider{ + command: exec.Command(command), + Duration: DefaultDuration, + Timeout: DefaultTimeout, + MaxBufSize: DefaultBufSize, + } + + for _, option := range options { + option(p) + } + + return credentials.NewCredentials(p) +} + +// NewCredentialsTimeout returns a pointer to a new Credentials object with +// the specified command and timeout, and default duration and max buffer size. +func NewCredentialsTimeout(command string, timeout time.Duration) *credentials.Credentials { + p := NewCredentials(command, func(opt *ProcessProvider) { + opt.Timeout = timeout + }) + + return p +} + +// NewCredentialsCommand returns a pointer to a new Credentials object with +// the specified command, and default timeout, duration and max buffer size. +func NewCredentialsCommand(command *exec.Cmd, options ...func(*ProcessProvider)) *credentials.Credentials { + p := &ProcessProvider{ + command: command, + Duration: DefaultDuration, + Timeout: DefaultTimeout, + MaxBufSize: DefaultBufSize, + } + + for _, option := range options { + option(p) + } + + return credentials.NewCredentials(p) +} + +type credentialProcessResponse struct { + Version int + AccessKeyID string `json:"AccessKeyId"` + SecretAccessKey string + SessionToken string + Expiration *time.Time +} + +// Retrieve executes the 'credential_process' and returns the credentials. +func (p *ProcessProvider) Retrieve() (credentials.Value, error) { + out, err := p.executeCredentialProcess() + if err != nil { + return credentials.Value{ProviderName: ProviderName}, err + } + + // Serialize and validate response + resp := &credentialProcessResponse{} + if err = json.Unmarshal(out, resp); err != nil { + return credentials.Value{ProviderName: ProviderName}, awserr.New( + ErrCodeProcessProviderParse, + fmt.Sprintf("%s: %s", errMsgProcessProviderParse, string(out)), + err) + } + + if resp.Version != 1 { + return credentials.Value{ProviderName: ProviderName}, awserr.New( + ErrCodeProcessProviderVersion, + errMsgProcessProviderVersion, + nil) + } + + if len(resp.AccessKeyID) == 0 { + return credentials.Value{ProviderName: ProviderName}, awserr.New( + ErrCodeProcessProviderRequired, + errMsgProcessProviderMissKey, + nil) + } + + if len(resp.SecretAccessKey) == 0 { + return credentials.Value{ProviderName: ProviderName}, awserr.New( + ErrCodeProcessProviderRequired, + errMsgProcessProviderMissSecret, + nil) + } + + // Handle expiration + p.staticCreds = resp.Expiration == nil + if resp.Expiration != nil { + p.SetExpiration(*resp.Expiration, p.ExpiryWindow) + } + + return credentials.Value{ + ProviderName: ProviderName, + AccessKeyID: resp.AccessKeyID, + SecretAccessKey: resp.SecretAccessKey, + SessionToken: resp.SessionToken, + }, nil +} + +// IsExpired returns true if the credentials retrieved are expired, or not yet +// retrieved. +func (p *ProcessProvider) IsExpired() bool { + if p.staticCreds { + return false + } + return p.Expiry.IsExpired() +} + +// prepareCommand prepares the command to be executed. +func (p *ProcessProvider) prepareCommand() error { + + var cmdArgs []string + if runtime.GOOS == "windows" { + cmdArgs = []string{"cmd.exe", "/C"} + } else { + cmdArgs = []string{"sh", "-c"} + } + + if len(p.originalCommand) == 0 { + p.originalCommand = make([]string, len(p.command.Args)) + copy(p.originalCommand, p.command.Args) + + // check for empty command because it succeeds + if len(strings.TrimSpace(p.originalCommand[0])) < 1 { + return awserr.New( + ErrCodeProcessProviderExecution, + fmt.Sprintf( + "%s: %s", + errMsgProcessProviderPrepareCmd, + errMsgProcessProviderEmptyCmd), + nil) + } + } + + cmdArgs = append(cmdArgs, p.originalCommand...) + p.command = exec.Command(cmdArgs[0], cmdArgs[1:]...) + p.command.Env = os.Environ() + + return nil +} + +// executeCredentialProcess starts the credential process on the OS and +// returns the results or an error. +func (p *ProcessProvider) executeCredentialProcess() ([]byte, error) { + + if err := p.prepareCommand(); err != nil { + return nil, err + } + + // Setup the pipes + outReadPipe, outWritePipe, err := os.Pipe() + if err != nil { + return nil, awserr.New( + ErrCodeProcessProviderExecution, + errMsgProcessProviderPipe, + err) + } + + p.command.Stderr = os.Stderr // display stderr on console for MFA + p.command.Stdout = outWritePipe // get creds json on process's stdout + p.command.Stdin = os.Stdin // enable stdin for MFA + + output := bytes.NewBuffer(make([]byte, 0, p.MaxBufSize)) + + stdoutCh := make(chan error, 1) + go readInput( + io.LimitReader(outReadPipe, int64(p.MaxBufSize)), + output, + stdoutCh) + + execCh := make(chan error, 1) + go executeCommand(*p.command, execCh) + + finished := false + var errors []error + for !finished { + select { + case readError := <-stdoutCh: + errors = appendError(errors, readError) + finished = true + case execError := <-execCh: + err := outWritePipe.Close() + errors = appendError(errors, err) + errors = appendError(errors, execError) + if errors != nil { + return output.Bytes(), awserr.NewBatchError( + ErrCodeProcessProviderExecution, + errMsgProcessProviderProcess, + errors) + } + case <-time.After(p.Timeout): + finished = true + return output.Bytes(), awserr.NewBatchError( + ErrCodeProcessProviderExecution, + errMsgProcessProviderTimeout, + errors) // errors can be nil + } + } + + out := output.Bytes() + + if runtime.GOOS == "windows" { + // windows adds slashes to quotes + out = []byte(strings.Replace(string(out), `\"`, `"`, -1)) + } + + return out, nil +} + +// appendError conveniently checks for nil before appending slice +func appendError(errors []error, err error) []error { + if err != nil { + return append(errors, err) + } + return errors +} + +func executeCommand(cmd exec.Cmd, exec chan error) { + // Start the command + err := cmd.Start() + if err == nil { + err = cmd.Wait() + } + + exec <- err +} + +func readInput(r io.Reader, w io.Writer, read chan error) { + tee := io.TeeReader(r, w) + + _, err := ioutil.ReadAll(tee) + + if err == io.EOF { + err = nil + } + + read <- err // will only arrive here when write end of pipe is closed +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go index 4f5dab3f..531139e3 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/credentials/static_provider.go @@ -9,8 +9,6 @@ const StaticProviderName = "StaticProvider" var ( // ErrStaticCredentialsEmpty is emitted when static credentials are empty. - // - // @readonly ErrStaticCredentialsEmpty = awserr.New("EmptyStaticCreds", "static credentials are empty", nil) ) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go index 6f57024d..5bacc791 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric.go @@ -3,6 +3,8 @@ package csm import ( "strconv" "time" + + "github.com/aws/aws-sdk-go/aws" ) type metricTime time.Time @@ -39,6 +41,12 @@ type metric struct { SDKException *string `json:"SdkException,omitempty"` SDKExceptionMessage *string `json:"SdkExceptionMessage,omitempty"` + FinalHTTPStatusCode *int `json:"FinalHttpStatusCode,omitempty"` + FinalAWSException *string `json:"FinalAwsException,omitempty"` + FinalAWSExceptionMessage *string `json:"FinalAwsExceptionMessage,omitempty"` + FinalSDKException *string `json:"FinalSdkException,omitempty"` + FinalSDKExceptionMessage *string `json:"FinalSdkExceptionMessage,omitempty"` + DestinationIP *string `json:"DestinationIp,omitempty"` ConnectionReused *int `json:"ConnectionReused,omitempty"` @@ -51,3 +59,51 @@ type metric struct { MaxRetriesExceeded *int `json:"MaxRetriesExceeded,omitempty"` } + +func (m *metric) TruncateFields() { + m.ClientID = truncateString(m.ClientID, 255) + m.UserAgent = truncateString(m.UserAgent, 256) + + m.AWSException = truncateString(m.AWSException, 128) + m.AWSExceptionMessage = truncateString(m.AWSExceptionMessage, 512) + + m.SDKException = truncateString(m.SDKException, 128) + m.SDKExceptionMessage = truncateString(m.SDKExceptionMessage, 512) + + m.FinalAWSException = truncateString(m.FinalAWSException, 128) + m.FinalAWSExceptionMessage = truncateString(m.FinalAWSExceptionMessage, 512) + + m.FinalSDKException = truncateString(m.FinalSDKException, 128) + m.FinalSDKExceptionMessage = truncateString(m.FinalSDKExceptionMessage, 512) +} + +func truncateString(v *string, l int) *string { + if v != nil && len(*v) > l { + nv := (*v)[:l] + return &nv + } + + return v +} + +func (m *metric) SetException(e metricException) { + switch te := e.(type) { + case awsException: + m.AWSException = aws.String(te.exception) + m.AWSExceptionMessage = aws.String(te.message) + case sdkException: + m.SDKException = aws.String(te.exception) + m.SDKExceptionMessage = aws.String(te.message) + } +} + +func (m *metric) SetFinalException(e metricException) { + switch te := e.(type) { + case awsException: + m.FinalAWSException = aws.String(te.exception) + m.FinalAWSExceptionMessage = aws.String(te.message) + case sdkException: + m.FinalSDKException = aws.String(te.exception) + m.FinalSDKExceptionMessage = aws.String(te.message) + } +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go new file mode 100644 index 00000000..54a99280 --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/metric_exception.go @@ -0,0 +1,26 @@ +package csm + +type metricException interface { + Exception() string + Message() string +} + +type requestException struct { + exception string + message string +} + +func (e requestException) Exception() string { + return e.exception +} +func (e requestException) Message() string { + return e.message +} + +type awsException struct { + requestException +} + +type sdkException struct { + requestException +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go index 11861844..0b5571ac 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/csm/reporter.go @@ -82,14 +82,15 @@ func (rep *Reporter) sendAPICallAttemptMetric(r *request.Request) { if r.Error != nil { if awserr, ok := r.Error.(awserr.Error); ok { - setError(&m, awserr) + m.SetException(getMetricException(awserr)) } } + m.TruncateFields() rep.metricsCh.Push(m) } -func setError(m *metric, err awserr.Error) { +func getMetricException(err awserr.Error) metricException { msg := err.Error() code := err.Code() @@ -97,11 +98,13 @@ func setError(m *metric, err awserr.Error) { case "RequestError", "SerializationError", request.CanceledErrorCode: - m.SDKException = &code - m.SDKExceptionMessage = &msg + return sdkException{ + requestException{exception: code, message: msg}, + } default: - m.AWSException = &code - m.AWSExceptionMessage = &msg + return awsException{ + requestException{exception: code, message: msg}, + } } } @@ -116,6 +119,7 @@ func (rep *Reporter) sendAPICallMetric(r *request.Request) { API: aws.String(r.Operation.Name), Service: aws.String(r.ClientInfo.ServiceID), Timestamp: (*metricTime)(&now), + UserAgent: aws.String(r.HTTPRequest.Header.Get("User-Agent")), Type: aws.String("ApiCall"), AttemptCount: aws.Int(r.RetryCount + 1), Region: r.Config.Region, @@ -124,6 +128,18 @@ func (rep *Reporter) sendAPICallMetric(r *request.Request) { MaxRetriesExceeded: aws.Int(boolIntValue(r.RetryCount >= r.MaxRetries())), } + if r.HTTPResponse != nil { + m.FinalHTTPStatusCode = aws.Int(r.HTTPResponse.StatusCode) + } + + if r.Error != nil { + if awserr, ok := r.Error.(awserr.Error); ok { + m.SetFinalException(getMetricException(awserr)) + } + } + + m.TruncateFields() + // TODO: Probably want to figure something out for logging dropped // metrics rep.metricsCh.Push(m) @@ -223,13 +239,15 @@ func (rep *Reporter) InjectHandlers(handlers *request.Handlers) { return } - apiCallHandler := request.NamedHandler{Name: APICallMetricHandlerName, Fn: rep.sendAPICallMetric} - apiCallAttemptHandler := request.NamedHandler{Name: APICallAttemptMetricHandlerName, Fn: rep.sendAPICallAttemptMetric} - - handlers.Complete.PushFrontNamed(apiCallHandler) - handlers.Complete.PushFrontNamed(apiCallAttemptHandler) + handlers.Complete.PushFrontNamed(request.NamedHandler{ + Name: APICallMetricHandlerName, + Fn: rep.sendAPICallMetric, + }) - handlers.AfterRetry.PushFrontNamed(apiCallAttemptHandler) + handlers.CompleteAttempt.PushFrontNamed(request.NamedHandler{ + Name: APICallAttemptMetricHandlerName, + Fn: rep.sendAPICallAttemptMetric, + }) } // boolIntValue return 1 for true and 0 for false. diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go index c215cd3f..88e2fc70 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/api.go @@ -118,6 +118,10 @@ func (c *EC2Metadata) Region() (string, error) { return "", err } + if len(resp) == 0 { + return "", awserr.New("EC2MetadataError", "invalid Region response", nil) + } + // returns region without the suffix. Eg: us-west-2a becomes us-west-2 return resp[:len(resp)-1], nil } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go index 53457cac..7d1f66e4 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/ec2metadata/service.go @@ -4,7 +4,7 @@ // This package's client can be disabled completely by setting the environment // variable "AWS_EC2_METADATA_DISABLED=true". This environment variable set to // true instructs the SDK to disable the EC2 Metadata client. The client cannot -// be used while the environemnt variable is set to true, (case insensitive). +// be used while the environment variable is set to true, (case insensitive). package ec2metadata import ( diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go index c04ba06c..87b9ff3f 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/decode.go @@ -85,6 +85,7 @@ func decodeV3Endpoints(modelDef modelDefinition, opts DecodeModelOptions) (Resol custAddS3DualStack(p) custRmIotDataService(p) custFixAppAutoscalingChina(p) + custFixAppAutoscalingUsGov(p) } return ps, nil @@ -95,7 +96,12 @@ func custAddS3DualStack(p *partition) { return } - s, ok := p.Services["s3"] + custAddDualstack(p, "s3") + custAddDualstack(p, "s3-control") +} + +func custAddDualstack(p *partition, svcName string) { + s, ok := p.Services[svcName] if !ok { return } @@ -103,7 +109,7 @@ func custAddS3DualStack(p *partition) { s.Defaults.HasDualStack = boxedTrue s.Defaults.DualStackHostname = "{service}.dualstack.{region}.{dnsSuffix}" - p.Services["s3"] = s + p.Services[svcName] = s } func custAddEC2Metadata(p *partition) { @@ -144,6 +150,33 @@ func custFixAppAutoscalingChina(p *partition) { p.Services[serviceName] = s } +func custFixAppAutoscalingUsGov(p *partition) { + if p.ID != "aws-us-gov" { + return + } + + const serviceName = "application-autoscaling" + s, ok := p.Services[serviceName] + if !ok { + return + } + + if a := s.Defaults.CredentialScope.Service; a != "" { + fmt.Printf("custFixAppAutoscalingUsGov: ignoring customization, expected empty credential scope service, got %s\n", a) + return + } + + if a := s.Defaults.Hostname; a != "" { + fmt.Printf("custFixAppAutoscalingUsGov: ignoring customization, expected empty hostname, got %s\n", a) + return + } + + s.Defaults.CredentialScope.Service = "application-autoscaling" + s.Defaults.Hostname = "autoscaling.{region}.amazonaws.com" + + p.Services[serviceName] = s +} + type decodeModelError struct { awsError } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go index 311277eb..97486c32 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/defaults.go @@ -22,6 +22,7 @@ const ( ApSoutheast2RegionID = "ap-southeast-2" // Asia Pacific (Sydney). CaCentral1RegionID = "ca-central-1" // Canada (Central). EuCentral1RegionID = "eu-central-1" // EU (Frankfurt). + EuNorth1RegionID = "eu-north-1" // EU (Stockholm). EuWest1RegionID = "eu-west-1" // EU (Ireland). EuWest2RegionID = "eu-west-2" // EU (London). EuWest3RegionID = "eu-west-3" // EU (Paris). @@ -40,141 +41,10 @@ const ( // AWS GovCloud (US) partition's regions. const ( + UsGovEast1RegionID = "us-gov-east-1" // AWS GovCloud (US-East). UsGovWest1RegionID = "us-gov-west-1" // AWS GovCloud (US). ) -// Service identifiers -const ( - A4bServiceID = "a4b" // A4b. - AcmServiceID = "acm" // Acm. - AcmPcaServiceID = "acm-pca" // AcmPca. - ApiMediatailorServiceID = "api.mediatailor" // ApiMediatailor. - ApiPricingServiceID = "api.pricing" // ApiPricing. - ApiSagemakerServiceID = "api.sagemaker" // ApiSagemaker. - ApigatewayServiceID = "apigateway" // Apigateway. - ApplicationAutoscalingServiceID = "application-autoscaling" // ApplicationAutoscaling. - Appstream2ServiceID = "appstream2" // Appstream2. - AthenaServiceID = "athena" // Athena. - AutoscalingServiceID = "autoscaling" // Autoscaling. - AutoscalingPlansServiceID = "autoscaling-plans" // AutoscalingPlans. - BatchServiceID = "batch" // Batch. - BudgetsServiceID = "budgets" // Budgets. - CeServiceID = "ce" // Ce. - Cloud9ServiceID = "cloud9" // Cloud9. - ClouddirectoryServiceID = "clouddirectory" // Clouddirectory. - CloudformationServiceID = "cloudformation" // Cloudformation. - CloudfrontServiceID = "cloudfront" // Cloudfront. - CloudhsmServiceID = "cloudhsm" // Cloudhsm. - Cloudhsmv2ServiceID = "cloudhsmv2" // Cloudhsmv2. - CloudsearchServiceID = "cloudsearch" // Cloudsearch. - CloudtrailServiceID = "cloudtrail" // Cloudtrail. - CodebuildServiceID = "codebuild" // Codebuild. - CodecommitServiceID = "codecommit" // Codecommit. - CodedeployServiceID = "codedeploy" // Codedeploy. - CodepipelineServiceID = "codepipeline" // Codepipeline. - CodestarServiceID = "codestar" // Codestar. - CognitoIdentityServiceID = "cognito-identity" // CognitoIdentity. - CognitoIdpServiceID = "cognito-idp" // CognitoIdp. - CognitoSyncServiceID = "cognito-sync" // CognitoSync. - ComprehendServiceID = "comprehend" // Comprehend. - ConfigServiceID = "config" // Config. - CurServiceID = "cur" // Cur. - DatapipelineServiceID = "datapipeline" // Datapipeline. - DaxServiceID = "dax" // Dax. - DevicefarmServiceID = "devicefarm" // Devicefarm. - DirectconnectServiceID = "directconnect" // Directconnect. - DiscoveryServiceID = "discovery" // Discovery. - DmsServiceID = "dms" // Dms. - DsServiceID = "ds" // Ds. - DynamodbServiceID = "dynamodb" // Dynamodb. - Ec2ServiceID = "ec2" // Ec2. - Ec2metadataServiceID = "ec2metadata" // Ec2metadata. - EcrServiceID = "ecr" // Ecr. - EcsServiceID = "ecs" // Ecs. - ElasticacheServiceID = "elasticache" // Elasticache. - ElasticbeanstalkServiceID = "elasticbeanstalk" // Elasticbeanstalk. - ElasticfilesystemServiceID = "elasticfilesystem" // Elasticfilesystem. - ElasticloadbalancingServiceID = "elasticloadbalancing" // Elasticloadbalancing. - ElasticmapreduceServiceID = "elasticmapreduce" // Elasticmapreduce. - ElastictranscoderServiceID = "elastictranscoder" // Elastictranscoder. - EmailServiceID = "email" // Email. - EntitlementMarketplaceServiceID = "entitlement.marketplace" // EntitlementMarketplace. - EsServiceID = "es" // Es. - EventsServiceID = "events" // Events. - FirehoseServiceID = "firehose" // Firehose. - FmsServiceID = "fms" // Fms. - GameliftServiceID = "gamelift" // Gamelift. - GlacierServiceID = "glacier" // Glacier. - GlueServiceID = "glue" // Glue. - GreengrassServiceID = "greengrass" // Greengrass. - GuarddutyServiceID = "guardduty" // Guardduty. - HealthServiceID = "health" // Health. - IamServiceID = "iam" // Iam. - ImportexportServiceID = "importexport" // Importexport. - InspectorServiceID = "inspector" // Inspector. - IotServiceID = "iot" // Iot. - IotanalyticsServiceID = "iotanalytics" // Iotanalytics. - KinesisServiceID = "kinesis" // Kinesis. - KinesisanalyticsServiceID = "kinesisanalytics" // Kinesisanalytics. - KinesisvideoServiceID = "kinesisvideo" // Kinesisvideo. - KmsServiceID = "kms" // Kms. - LambdaServiceID = "lambda" // Lambda. - LightsailServiceID = "lightsail" // Lightsail. - LogsServiceID = "logs" // Logs. - MachinelearningServiceID = "machinelearning" // Machinelearning. - MarketplacecommerceanalyticsServiceID = "marketplacecommerceanalytics" // Marketplacecommerceanalytics. - MediaconvertServiceID = "mediaconvert" // Mediaconvert. - MedialiveServiceID = "medialive" // Medialive. - MediapackageServiceID = "mediapackage" // Mediapackage. - MediastoreServiceID = "mediastore" // Mediastore. - MeteringMarketplaceServiceID = "metering.marketplace" // MeteringMarketplace. - MghServiceID = "mgh" // Mgh. - MobileanalyticsServiceID = "mobileanalytics" // Mobileanalytics. - ModelsLexServiceID = "models.lex" // ModelsLex. - MonitoringServiceID = "monitoring" // Monitoring. - MturkRequesterServiceID = "mturk-requester" // MturkRequester. - NeptuneServiceID = "neptune" // Neptune. - OpsworksServiceID = "opsworks" // Opsworks. - OpsworksCmServiceID = "opsworks-cm" // OpsworksCm. - OrganizationsServiceID = "organizations" // Organizations. - PinpointServiceID = "pinpoint" // Pinpoint. - PollyServiceID = "polly" // Polly. - RdsServiceID = "rds" // Rds. - RedshiftServiceID = "redshift" // Redshift. - RekognitionServiceID = "rekognition" // Rekognition. - ResourceGroupsServiceID = "resource-groups" // ResourceGroups. - Route53ServiceID = "route53" // Route53. - Route53domainsServiceID = "route53domains" // Route53domains. - RuntimeLexServiceID = "runtime.lex" // RuntimeLex. - RuntimeSagemakerServiceID = "runtime.sagemaker" // RuntimeSagemaker. - S3ServiceID = "s3" // S3. - SdbServiceID = "sdb" // Sdb. - SecretsmanagerServiceID = "secretsmanager" // Secretsmanager. - ServerlessrepoServiceID = "serverlessrepo" // Serverlessrepo. - ServicecatalogServiceID = "servicecatalog" // Servicecatalog. - ServicediscoveryServiceID = "servicediscovery" // Servicediscovery. - ShieldServiceID = "shield" // Shield. - SmsServiceID = "sms" // Sms. - SnowballServiceID = "snowball" // Snowball. - SnsServiceID = "sns" // Sns. - SqsServiceID = "sqs" // Sqs. - SsmServiceID = "ssm" // Ssm. - StatesServiceID = "states" // States. - StoragegatewayServiceID = "storagegateway" // Storagegateway. - StreamsDynamodbServiceID = "streams.dynamodb" // StreamsDynamodb. - StsServiceID = "sts" // Sts. - SupportServiceID = "support" // Support. - SwfServiceID = "swf" // Swf. - TaggingServiceID = "tagging" // Tagging. - TranslateServiceID = "translate" // Translate. - WafServiceID = "waf" // Waf. - WafRegionalServiceID = "waf-regional" // WafRegional. - WorkdocsServiceID = "workdocs" // Workdocs. - WorkmailServiceID = "workmail" // Workmail. - WorkspacesServiceID = "workspaces" // Workspaces. - XrayServiceID = "xray" // Xray. -) - // DefaultResolver returns an Endpoint resolver that will be able // to resolve endpoints for: AWS Standard, AWS China, and AWS GovCloud (US). // @@ -242,6 +112,9 @@ var awsPartition = partition{ "eu-central-1": region{ Description: "EU (Frankfurt)", }, + "eu-north-1": region{ + Description: "EU (Stockholm)", + }, "eu-west-1": region{ Description: "EU (Ireland)", }, @@ -284,6 +157,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -311,6 +185,107 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "api.ecr": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{ + Hostname: "api.ecr.ap-northeast-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-northeast-1", + }, + }, + "ap-northeast-2": endpoint{ + Hostname: "api.ecr.ap-northeast-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-northeast-2", + }, + }, + "ap-south-1": endpoint{ + Hostname: "api.ecr.ap-south-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-south-1", + }, + }, + "ap-southeast-1": endpoint{ + Hostname: "api.ecr.ap-southeast-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-southeast-1", + }, + }, + "ap-southeast-2": endpoint{ + Hostname: "api.ecr.ap-southeast-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-southeast-2", + }, + }, + "ca-central-1": endpoint{ + Hostname: "api.ecr.ca-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + }, + "eu-central-1": endpoint{ + Hostname: "api.ecr.eu-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-central-1", + }, + }, + "eu-north-1": endpoint{ + Hostname: "api.ecr.eu-north-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-north-1", + }, + }, + "eu-west-1": endpoint{ + Hostname: "api.ecr.eu-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-west-1", + }, + }, + "eu-west-2": endpoint{ + Hostname: "api.ecr.eu-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-west-2", + }, + }, + "eu-west-3": endpoint{ + Hostname: "api.ecr.eu-west-3.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-west-3", + }, + }, + "sa-east-1": endpoint{ + Hostname: "api.ecr.sa-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "sa-east-1", + }, + }, + "us-east-1": endpoint{ + Hostname: "api.ecr.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "us-east-2": endpoint{ + Hostname: "api.ecr.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "us-west-1": endpoint{ + Hostname: "api.ecr.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "us-west-2": endpoint{ + Hostname: "api.ecr.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + }, + }, "api.mediatailor": service{ Endpoints: endpoints{ @@ -319,6 +294,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "api.pricing": service{ @@ -337,11 +313,16 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -355,6 +336,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -381,6 +363,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -400,8 +383,26 @@ var awsPartition = partition{ }, Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "appsync": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, + "us-east-2": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -433,6 +434,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -452,10 +454,18 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -471,6 +481,7 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -504,6 +515,23 @@ var awsPartition = partition{ }, }, }, + "chime": service{ + PartitionEndpoint: "aws-global", + IsRegionalized: boxedFalse, + Defaults: endpoint{ + SSLCommonName: "service.chime.aws.amazon.com", + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "aws-global": endpoint{ + Hostname: "service.chime.aws.amazon.com", + Protocols: []string{"https"}, + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + }, + }, "cloud9": service{ Endpoints: endpoints{ @@ -519,6 +547,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, @@ -537,6 +566,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -584,13 +614,16 @@ var awsPartition = partition{ }, Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -622,6 +655,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -689,11 +723,17 @@ var awsPartition = partition{ "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "fips": endpoint{ + Hostname: "codecommit-fips.ca-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + }, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "codedeploy": service{ @@ -706,14 +746,39 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, + "us-east-1-fips": endpoint{ + Hostname: "codedeploy-fips.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "us-east-2": endpoint{}, + "us-east-2-fips": endpoint{ + Hostname: "codedeploy-fips.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "us-west-1": endpoint{}, + "us-west-1-fips": endpoint{ + Hostname: "codedeploy-fips.us-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "us-west-2": endpoint{}, + "us-west-2-fips": endpoint{ + Hostname: "codedeploy-fips.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, }, }, "codepipeline": service{ @@ -809,6 +874,7 @@ var awsPartition = partition{ }, Endpoints: endpoints{ "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -825,6 +891,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -851,6 +918,21 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "datasync": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "dax": service{ Endpoints: endpoints{ @@ -882,6 +964,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -918,6 +1001,35 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "docdb": service{ + + Endpoints: endpoints{ + "eu-west-1": endpoint{ + Hostname: "rds.eu-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-west-1", + }, + }, + "us-east-1": endpoint{ + Hostname: "rds.us-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "us-east-2": endpoint{ + Hostname: "rds.us-east-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "us-west-2": endpoint{ + Hostname: "rds.us-west-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + }, + }, "ds": service{ Endpoints: endpoints{ @@ -949,6 +1061,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -978,6 +1091,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -999,26 +1113,6 @@ var awsPartition = partition{ }, }, }, - "ecr": service{ - - Endpoints: endpoints{ - "ap-northeast-1": endpoint{}, - "ap-northeast-2": endpoint{}, - "ap-south-1": endpoint{}, - "ap-southeast-1": endpoint{}, - "ap-southeast-2": endpoint{}, - "ca-central-1": endpoint{}, - "eu-central-1": endpoint{}, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, - "us-east-1": endpoint{}, - "us-east-2": endpoint{}, - "us-west-1": endpoint{}, - "us-west-2": endpoint{}, - }, - }, "ecs": service{ Endpoints: endpoints{ @@ -1029,6 +1123,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1049,6 +1144,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1075,6 +1171,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1112,6 +1209,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1137,10 +1235,11 @@ var awsPartition = partition{ "eu-central-1": endpoint{ SSLCommonName: "{service}.{region}.{dnsSuffix}", }, - "eu-west-1": endpoint{}, - "eu-west-2": endpoint{}, - "eu-west-3": endpoint{}, - "sa-east-1": endpoint{}, + "eu-north-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{ SSLCommonName: "{service}.{region}.{dnsSuffix}", }, @@ -1190,6 +1289,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1210,6 +1310,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1244,9 +1345,22 @@ var awsPartition = partition{ Defaults: endpoint{ Protocols: []string{"https"}, }, + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "fsx": service{ + Endpoints: endpoints{ "eu-west-1": endpoint{}, "us-east-1": endpoint{}, + "us-east-2": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -1281,9 +1395,11 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -1302,8 +1418,10 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -1417,6 +1535,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, + "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -1433,6 +1552,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1449,6 +1569,7 @@ var awsPartition = partition{ "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, "us-east-1": endpoint{}, + "us-east-2": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -1472,6 +1593,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1492,6 +1614,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1530,6 +1653,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1592,6 +1716,7 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, "eu-central-1": endpoint{}, @@ -1629,6 +1754,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1675,6 +1801,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1685,19 +1812,52 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, - "mturk-requester": service{ - IsRegionalized: boxedFalse, + "mq": service{ Endpoints: endpoints{ - "sandbox": endpoint{ - Hostname: "mturk-requester-sandbox.us-east-1.amazonaws.com", - }, - "us-east-1": endpoint{}, - }, + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, + "mturk-requester": service{ + IsRegionalized: boxedFalse, + + Endpoints: endpoints{ + "sandbox": endpoint{ + Hostname: "mturk-requester-sandbox.us-east-1.amazonaws.com", + }, + "us-east-1": endpoint{}, + }, }, "neptune": service{ Endpoints: endpoints{ + "ap-southeast-1": endpoint{ + Hostname: "rds.ap-southeast-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-southeast-1", + }, + }, + "ap-southeast-2": endpoint{ + Hostname: "rds.ap-southeast-2.amazonaws.com", + CredentialScope: credentialScope{ + Region: "ap-southeast-2", + }, + }, + "eu-central-1": endpoint{ + Hostname: "rds.eu-central-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "eu-central-1", + }, + }, "eu-west-1": endpoint{ Hostname: "rds.eu-west-1.amazonaws.com", CredentialScope: credentialScope{ @@ -1784,7 +1944,10 @@ var awsPartition = partition{ }, }, Endpoints: endpoints{ - "us-east-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, }, }, "polly": service{ @@ -1817,6 +1980,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1839,6 +2003,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1870,6 +2035,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -1880,6 +2046,14 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "robomaker": service{ + + Endpoints: endpoints{ + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "route53": service{ PartitionEndpoint: "aws-global", IsRegionalized: boxedFalse, @@ -1899,6 +2073,20 @@ var awsPartition = partition{ "us-east-1": endpoint{}, }, }, + "route53resolver": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "eu-west-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "runtime.lex": service{ Defaults: endpoint{ CredentialScope: credentialScope{ @@ -1916,11 +2104,16 @@ var awsPartition = partition{ Endpoints: endpoints{ "ap-northeast-1": endpoint{}, "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, + "us-west-1": endpoint{}, "us-west-2": endpoint{}, }, }, @@ -1951,6 +2144,7 @@ var awsPartition = partition{ }, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{ Hostname: "s3.eu-west-1.amazonaws.com", SignatureVersions: []string{"s3", "s3v4"}, @@ -1983,6 +2177,157 @@ var awsPartition = partition{ }, }, }, + "s3-control": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + SignatureVersions: []string{"s3v4"}, + + HasDualStack: boxedTrue, + DualStackHostname: "{service}.dualstack.{region}.{dnsSuffix}", + }, + Endpoints: endpoints{ + "ap-northeast-1": endpoint{ + Hostname: "s3-control.ap-northeast-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "ap-northeast-1", + }, + }, + "ap-northeast-2": endpoint{ + Hostname: "s3-control.ap-northeast-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "ap-northeast-2", + }, + }, + "ap-south-1": endpoint{ + Hostname: "s3-control.ap-south-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "ap-south-1", + }, + }, + "ap-southeast-1": endpoint{ + Hostname: "s3-control.ap-southeast-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "ap-southeast-1", + }, + }, + "ap-southeast-2": endpoint{ + Hostname: "s3-control.ap-southeast-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "ap-southeast-2", + }, + }, + "ca-central-1": endpoint{ + Hostname: "s3-control.ca-central-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "ca-central-1", + }, + }, + "eu-central-1": endpoint{ + Hostname: "s3-control.eu-central-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "eu-central-1", + }, + }, + "eu-north-1": endpoint{ + Hostname: "s3-control.eu-north-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "eu-north-1", + }, + }, + "eu-west-1": endpoint{ + Hostname: "s3-control.eu-west-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "eu-west-1", + }, + }, + "eu-west-2": endpoint{ + Hostname: "s3-control.eu-west-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "eu-west-2", + }, + }, + "eu-west-3": endpoint{ + Hostname: "s3-control.eu-west-3.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "eu-west-3", + }, + }, + "sa-east-1": endpoint{ + Hostname: "s3-control.sa-east-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "sa-east-1", + }, + }, + "us-east-1": endpoint{ + Hostname: "s3-control.us-east-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "us-east-1-fips": endpoint{ + Hostname: "s3-control-fips.us-east-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-east-1", + }, + }, + "us-east-2": endpoint{ + Hostname: "s3-control.us-east-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "us-east-2-fips": endpoint{ + Hostname: "s3-control-fips.us-east-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-east-2", + }, + }, + "us-west-1": endpoint{ + Hostname: "s3-control.us-west-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "us-west-1-fips": endpoint{ + Hostname: "s3-control-fips.us-west-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-west-1", + }, + }, + "us-west-2": endpoint{ + Hostname: "s3-control.us-west-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + "us-west-2-fips": endpoint{ + Hostname: "s3-control-fips.us-west-2.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-west-2", + }, + }, + }, + }, "sdb": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -2045,6 +2390,26 @@ var awsPartition = partition{ }, }, }, + "securityhub": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-south-1": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "serverlessrepo": service{ Defaults: endpoint{ Protocols: []string{"https"}, @@ -2161,7 +2526,7 @@ var awsPartition = partition{ "shield": service{ IsRegionalized: boxedFalse, Defaults: endpoint{ - SSLCommonName: "Shield.us-east-1.amazonaws.com", + SSLCommonName: "shield.us-east-1.amazonaws.com", Protocols: []string{"https"}, }, Endpoints: endpoints{ @@ -2219,6 +2584,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2242,6 +2608,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2288,6 +2655,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2308,8 +2676,11 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, "us-west-1": endpoint{}, @@ -2326,6 +2697,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2351,6 +2723,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2390,6 +2763,7 @@ var awsPartition = partition{ "aws-global": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2440,6 +2814,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2460,6 +2835,7 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, "eu-west-3": endpoint{}, @@ -2470,6 +2846,24 @@ var awsPartition = partition{ "us-west-2": endpoint{}, }, }, + "transfer": service{ + + Endpoints: endpoints{ + "ap-northeast-1": endpoint{}, + "ap-northeast-2": endpoint{}, + "ap-southeast-1": endpoint{}, + "ap-southeast-2": endpoint{}, + "ca-central-1": endpoint{}, + "eu-central-1": endpoint{}, + "eu-west-1": endpoint{}, + "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, + "us-east-1": endpoint{}, + "us-east-2": endpoint{}, + "us-west-1": endpoint{}, + "us-west-2": endpoint{}, + }, + }, "translate": service{ Defaults: endpoint{ Protocols: []string{"https"}, @@ -2572,8 +2966,10 @@ var awsPartition = partition{ "ap-southeast-2": endpoint{}, "ca-central-1": endpoint{}, "eu-central-1": endpoint{}, + "eu-north-1": endpoint{}, "eu-west-1": endpoint{}, "eu-west-2": endpoint{}, + "eu-west-3": endpoint{}, "sa-east-1": endpoint{}, "us-east-1": endpoint{}, "us-east-2": endpoint{}, @@ -2613,6 +3009,23 @@ var awscnPartition = partition{ }, }, Services: services{ + "api.ecr": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{ + Hostname: "api.ecr.cn-north-1.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-north-1", + }, + }, + "cn-northwest-1": endpoint{ + Hostname: "api.ecr.cn-northwest-1.amazonaws.com.cn", + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, + }, + }, "apigateway": service{ Endpoints: endpoints{ @@ -2690,6 +3103,13 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "dms": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "ds": service{ Endpoints: endpoints{ @@ -2726,13 +3146,6 @@ var awscnPartition = partition{ }, }, }, - "ecr": service{ - - Endpoints: endpoints{ - "cn-north-1": endpoint{}, - "cn-northwest-1": endpoint{}, - }, - }, "ecs": service{ Endpoints: endpoints{ @@ -2775,6 +3188,7 @@ var awscnPartition = partition{ "es": service{ Endpoints: endpoints{ + "cn-north-1": endpoint{}, "cn-northwest-1": endpoint{}, }, }, @@ -2785,6 +3199,13 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "firehose": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "glacier": service{ Defaults: endpoint{ Protocols: []string{"http", "https"}, @@ -2847,6 +3268,12 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "polly": service{ + + Endpoints: endpoints{ + "cn-northwest-1": endpoint{}, + }, + }, "rds": service{ Endpoints: endpoints{ @@ -2871,6 +3298,28 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "s3-control": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + SignatureVersions: []string{"s3v4"}, + }, + Endpoints: endpoints{ + "cn-north-1": endpoint{ + Hostname: "s3-control.cn-north-1.amazonaws.com.cn", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "cn-north-1", + }, + }, + "cn-northwest-1": endpoint{ + Hostname: "s3-control.cn-northwest-1.amazonaws.com.cn", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "cn-northwest-1", + }, + }, + }, + }, "sms": service{ Endpoints: endpoints{ @@ -2910,6 +3359,13 @@ var awscnPartition = partition{ "cn-northwest-1": endpoint{}, }, }, + "states": service{ + + Endpoints: endpoints{ + "cn-north-1": endpoint{}, + "cn-northwest-1": endpoint{}, + }, + }, "storagegateway": service{ Endpoints: endpoints{ @@ -2973,6 +3429,9 @@ var awsusgovPartition = partition{ SignatureVersions: []string{"v4"}, }, Regions: regions{ + "us-gov-east-1": region{ + Description: "AWS GovCloud (US-East)", + }, "us-gov-west-1": region{ Description: "AWS GovCloud (US)", }, @@ -2981,9 +3440,27 @@ var awsusgovPartition = partition{ "acm": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, + "api.ecr": service{ + + Endpoints: endpoints{ + "us-gov-east-1": endpoint{ + Hostname: "api.ecr.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "us-gov-west-1": endpoint{ + Hostname: "api.ecr.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, + }, + }, "api.sagemaker": service{ Endpoints: endpoints{ @@ -2993,26 +3470,41 @@ var awsusgovPartition = partition{ "apigateway": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "application-autoscaling": service{ - + Defaults: endpoint{ + Hostname: "autoscaling.{region}.amazonaws.com", + CredentialScope: credentialScope{ + Service: "application-autoscaling", + }, + }, Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "autoscaling": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, }, }, + "clouddirectory": service{ + + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, "cloudformation": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3029,35 +3521,59 @@ var awsusgovPartition = partition{ }, }, Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "cloudtrail": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "codedeploy": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-east-1-fips": endpoint{ + Hostname: "codedeploy-fips.us-gov-east-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, "us-gov-west-1": endpoint{}, + "us-gov-west-1-fips": endpoint{ + Hostname: "codedeploy-fips.us-gov-west-1.amazonaws.com", + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, }, }, "config": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "directconnect": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "dms": service{ + Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, + "ds": service{ + Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -3065,6 +3581,7 @@ var awsusgovPartition = partition{ "dynamodb": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, "us-gov-west-1-fips": endpoint{ Hostname: "dynamodb.us-gov-west-1.amazonaws.com", @@ -3077,6 +3594,7 @@ var awsusgovPartition = partition{ "ec2": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3091,15 +3609,10 @@ var awsusgovPartition = partition{ }, }, }, - "ecr": service{ - - Endpoints: endpoints{ - "us-gov-west-1": endpoint{}, - }, - }, "ecs": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3112,11 +3625,19 @@ var awsusgovPartition = partition{ Region: "us-gov-west-1", }, }, + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "elasticbeanstalk": service{ + Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, + "elasticfilesystem": service{ + Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -3124,6 +3645,7 @@ var awsusgovPartition = partition{ "elasticloadbalancing": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, @@ -3132,6 +3654,7 @@ var awsusgovPartition = partition{ "elasticmapreduce": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"https"}, }, @@ -3140,11 +3663,19 @@ var awsusgovPartition = partition{ "es": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "events": service{ + Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, + "firehose": service{ + Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -3152,11 +3683,21 @@ var awsusgovPartition = partition{ "glacier": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, }, }, + "guardduty": service{ + IsRegionalized: boxedTrue, + Defaults: endpoint{ + Protocols: []string{"https"}, + }, + Endpoints: endpoints{ + "us-gov-west-1": endpoint{}, + }, + }, "iam": service{ PartitionEndpoint: "aws-us-gov-global", IsRegionalized: boxedFalse, @@ -3173,6 +3714,7 @@ var awsusgovPartition = partition{ "inspector": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3189,23 +3731,33 @@ var awsusgovPartition = partition{ "kinesis": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "kms": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "lambda": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "logs": service{ + Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, + "us-gov-west-1": endpoint{}, + }, + }, + "mediaconvert": service{ + Endpoints: endpoints{ "us-gov-west-1": endpoint{}, }, @@ -3223,6 +3775,7 @@ var awsusgovPartition = partition{ "monitoring": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3235,12 +3788,14 @@ var awsusgovPartition = partition{ "rds": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "redshift": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3267,27 +3822,70 @@ var awsusgovPartition = partition{ Region: "us-gov-west-1", }, }, + "us-gov-east-1": endpoint{ + Hostname: "s3.us-gov-east-1.amazonaws.com", + Protocols: []string{"http", "https"}, + }, "us-gov-west-1": endpoint{ Hostname: "s3.us-gov-west-1.amazonaws.com", Protocols: []string{"http", "https"}, }, }, }, + "s3-control": service{ + Defaults: endpoint{ + Protocols: []string{"https"}, + SignatureVersions: []string{"s3v4"}, + }, + Endpoints: endpoints{ + "us-gov-east-1": endpoint{ + Hostname: "s3-control.us-gov-east-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "us-gov-east-1-fips": endpoint{ + Hostname: "s3-control-fips.us-gov-east-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-gov-east-1", + }, + }, + "us-gov-west-1": endpoint{ + Hostname: "s3-control.us-gov-west-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, + "us-gov-west-1-fips": endpoint{ + Hostname: "s3-control-fips.us-gov-west-1.amazonaws.com", + SignatureVersions: []string{"s3v4"}, + CredentialScope: credentialScope{ + Region: "us-gov-west-1", + }, + }, + }, + }, "sms": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "snowball": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "sns": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ Protocols: []string{"http", "https"}, }, @@ -3296,6 +3894,7 @@ var awsusgovPartition = partition{ "sqs": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{ SSLCommonName: "{region}.queue.{dnsSuffix}", Protocols: []string{"http", "https"}, @@ -3305,12 +3904,14 @@ var awsusgovPartition = partition{ "ssm": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "states": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, @@ -3327,6 +3928,7 @@ var awsusgovPartition = partition{ }, }, Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, "us-gov-west-1-fips": endpoint{ Hostname: "dynamodb.us-gov-west-1.amazonaws.com", @@ -3339,18 +3941,21 @@ var awsusgovPartition = partition{ "sts": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "swf": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, "tagging": service{ Endpoints: endpoints{ + "us-gov-east-1": endpoint{}, "us-gov-west-1": endpoint{}, }, }, diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go new file mode 100644 index 00000000..000dd79e --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/dep_service_ids.go @@ -0,0 +1,141 @@ +package endpoints + +// Service identifiers +// +// Deprecated: Use client package's EndpointID value instead of these +// ServiceIDs. These IDs are not maintained, and are out of date. +const ( + A4bServiceID = "a4b" // A4b. + AcmServiceID = "acm" // Acm. + AcmPcaServiceID = "acm-pca" // AcmPca. + ApiMediatailorServiceID = "api.mediatailor" // ApiMediatailor. + ApiPricingServiceID = "api.pricing" // ApiPricing. + ApiSagemakerServiceID = "api.sagemaker" // ApiSagemaker. + ApigatewayServiceID = "apigateway" // Apigateway. + ApplicationAutoscalingServiceID = "application-autoscaling" // ApplicationAutoscaling. + Appstream2ServiceID = "appstream2" // Appstream2. + AppsyncServiceID = "appsync" // Appsync. + AthenaServiceID = "athena" // Athena. + AutoscalingServiceID = "autoscaling" // Autoscaling. + AutoscalingPlansServiceID = "autoscaling-plans" // AutoscalingPlans. + BatchServiceID = "batch" // Batch. + BudgetsServiceID = "budgets" // Budgets. + CeServiceID = "ce" // Ce. + ChimeServiceID = "chime" // Chime. + Cloud9ServiceID = "cloud9" // Cloud9. + ClouddirectoryServiceID = "clouddirectory" // Clouddirectory. + CloudformationServiceID = "cloudformation" // Cloudformation. + CloudfrontServiceID = "cloudfront" // Cloudfront. + CloudhsmServiceID = "cloudhsm" // Cloudhsm. + Cloudhsmv2ServiceID = "cloudhsmv2" // Cloudhsmv2. + CloudsearchServiceID = "cloudsearch" // Cloudsearch. + CloudtrailServiceID = "cloudtrail" // Cloudtrail. + CodebuildServiceID = "codebuild" // Codebuild. + CodecommitServiceID = "codecommit" // Codecommit. + CodedeployServiceID = "codedeploy" // Codedeploy. + CodepipelineServiceID = "codepipeline" // Codepipeline. + CodestarServiceID = "codestar" // Codestar. + CognitoIdentityServiceID = "cognito-identity" // CognitoIdentity. + CognitoIdpServiceID = "cognito-idp" // CognitoIdp. + CognitoSyncServiceID = "cognito-sync" // CognitoSync. + ComprehendServiceID = "comprehend" // Comprehend. + ConfigServiceID = "config" // Config. + CurServiceID = "cur" // Cur. + DatapipelineServiceID = "datapipeline" // Datapipeline. + DaxServiceID = "dax" // Dax. + DevicefarmServiceID = "devicefarm" // Devicefarm. + DirectconnectServiceID = "directconnect" // Directconnect. + DiscoveryServiceID = "discovery" // Discovery. + DmsServiceID = "dms" // Dms. + DsServiceID = "ds" // Ds. + DynamodbServiceID = "dynamodb" // Dynamodb. + Ec2ServiceID = "ec2" // Ec2. + Ec2metadataServiceID = "ec2metadata" // Ec2metadata. + EcrServiceID = "ecr" // Ecr. + EcsServiceID = "ecs" // Ecs. + ElasticacheServiceID = "elasticache" // Elasticache. + ElasticbeanstalkServiceID = "elasticbeanstalk" // Elasticbeanstalk. + ElasticfilesystemServiceID = "elasticfilesystem" // Elasticfilesystem. + ElasticloadbalancingServiceID = "elasticloadbalancing" // Elasticloadbalancing. + ElasticmapreduceServiceID = "elasticmapreduce" // Elasticmapreduce. + ElastictranscoderServiceID = "elastictranscoder" // Elastictranscoder. + EmailServiceID = "email" // Email. + EntitlementMarketplaceServiceID = "entitlement.marketplace" // EntitlementMarketplace. + EsServiceID = "es" // Es. + EventsServiceID = "events" // Events. + FirehoseServiceID = "firehose" // Firehose. + FmsServiceID = "fms" // Fms. + GameliftServiceID = "gamelift" // Gamelift. + GlacierServiceID = "glacier" // Glacier. + GlueServiceID = "glue" // Glue. + GreengrassServiceID = "greengrass" // Greengrass. + GuarddutyServiceID = "guardduty" // Guardduty. + HealthServiceID = "health" // Health. + IamServiceID = "iam" // Iam. + ImportexportServiceID = "importexport" // Importexport. + InspectorServiceID = "inspector" // Inspector. + IotServiceID = "iot" // Iot. + IotanalyticsServiceID = "iotanalytics" // Iotanalytics. + KinesisServiceID = "kinesis" // Kinesis. + KinesisanalyticsServiceID = "kinesisanalytics" // Kinesisanalytics. + KinesisvideoServiceID = "kinesisvideo" // Kinesisvideo. + KmsServiceID = "kms" // Kms. + LambdaServiceID = "lambda" // Lambda. + LightsailServiceID = "lightsail" // Lightsail. + LogsServiceID = "logs" // Logs. + MachinelearningServiceID = "machinelearning" // Machinelearning. + MarketplacecommerceanalyticsServiceID = "marketplacecommerceanalytics" // Marketplacecommerceanalytics. + MediaconvertServiceID = "mediaconvert" // Mediaconvert. + MedialiveServiceID = "medialive" // Medialive. + MediapackageServiceID = "mediapackage" // Mediapackage. + MediastoreServiceID = "mediastore" // Mediastore. + MeteringMarketplaceServiceID = "metering.marketplace" // MeteringMarketplace. + MghServiceID = "mgh" // Mgh. + MobileanalyticsServiceID = "mobileanalytics" // Mobileanalytics. + ModelsLexServiceID = "models.lex" // ModelsLex. + MonitoringServiceID = "monitoring" // Monitoring. + MturkRequesterServiceID = "mturk-requester" // MturkRequester. + NeptuneServiceID = "neptune" // Neptune. + OpsworksServiceID = "opsworks" // Opsworks. + OpsworksCmServiceID = "opsworks-cm" // OpsworksCm. + OrganizationsServiceID = "organizations" // Organizations. + PinpointServiceID = "pinpoint" // Pinpoint. + PollyServiceID = "polly" // Polly. + RdsServiceID = "rds" // Rds. + RedshiftServiceID = "redshift" // Redshift. + RekognitionServiceID = "rekognition" // Rekognition. + ResourceGroupsServiceID = "resource-groups" // ResourceGroups. + Route53ServiceID = "route53" // Route53. + Route53domainsServiceID = "route53domains" // Route53domains. + RuntimeLexServiceID = "runtime.lex" // RuntimeLex. + RuntimeSagemakerServiceID = "runtime.sagemaker" // RuntimeSagemaker. + S3ServiceID = "s3" // S3. + S3ControlServiceID = "s3-control" // S3Control. + SagemakerServiceID = "api.sagemaker" // Sagemaker. + SdbServiceID = "sdb" // Sdb. + SecretsmanagerServiceID = "secretsmanager" // Secretsmanager. + ServerlessrepoServiceID = "serverlessrepo" // Serverlessrepo. + ServicecatalogServiceID = "servicecatalog" // Servicecatalog. + ServicediscoveryServiceID = "servicediscovery" // Servicediscovery. + ShieldServiceID = "shield" // Shield. + SmsServiceID = "sms" // Sms. + SnowballServiceID = "snowball" // Snowball. + SnsServiceID = "sns" // Sns. + SqsServiceID = "sqs" // Sqs. + SsmServiceID = "ssm" // Ssm. + StatesServiceID = "states" // States. + StoragegatewayServiceID = "storagegateway" // Storagegateway. + StreamsDynamodbServiceID = "streams.dynamodb" // StreamsDynamodb. + StsServiceID = "sts" // Sts. + SupportServiceID = "support" // Support. + SwfServiceID = "swf" // Swf. + TaggingServiceID = "tagging" // Tagging. + TransferServiceID = "transfer" // Transfer. + TranslateServiceID = "translate" // Translate. + WafServiceID = "waf" // Waf. + WafRegionalServiceID = "waf-regional" // WafRegional. + WorkdocsServiceID = "workdocs" // Workdocs. + WorkmailServiceID = "workmail" // Workmail. + WorkspacesServiceID = "workspaces" // Workspaces. + XrayServiceID = "xray" // Xray. +) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go index e29c0951..f82babf6 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/endpoints.go @@ -35,7 +35,7 @@ type Options struct { // // If resolving an endpoint on the partition list the provided region will // be used to determine which partition's domain name pattern to the service - // endpoint ID with. If both the service and region are unkonwn and resolving + // endpoint ID with. If both the service and region are unknown and resolving // the endpoint on partition list an UnknownEndpointError error will be returned. // // If resolving and endpoint on a partition specific resolver that partition's diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go index 05e92df2..0fdfcc56 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/endpoints/v3model_codegen.go @@ -16,6 +16,10 @@ import ( type CodeGenOptions struct { // Options for how the model will be decoded. DecodeModelOptions DecodeModelOptions + + // Disables code generation of the service endpoint prefix IDs defined in + // the model. + DisableGenerateServiceIDs bool } // Set combines all of the option functions together @@ -39,8 +43,16 @@ func CodeGenModel(modelFile io.Reader, outFile io.Writer, optFns ...func(*CodeGe return err } + v := struct { + Resolver + CodeGenOptions + }{ + Resolver: resolver, + CodeGenOptions: opts, + } + tmpl := template.Must(template.New("tmpl").Funcs(funcMap).Parse(v3Tmpl)) - if err := tmpl.ExecuteTemplate(outFile, "defaults", resolver); err != nil { + if err := tmpl.ExecuteTemplate(outFile, "defaults", v); err != nil { return fmt.Errorf("failed to execute template, %v", err) } @@ -166,15 +178,17 @@ import ( "regexp" ) - {{ template "partition consts" . }} + {{ template "partition consts" $.Resolver }} - {{ range $_, $partition := . }} + {{ range $_, $partition := $.Resolver }} {{ template "partition region consts" $partition }} {{ end }} - {{ template "service consts" . }} + {{ if not $.DisableGenerateServiceIDs -}} + {{ template "service consts" $.Resolver }} + {{- end }} - {{ template "endpoint resolvers" . }} + {{ template "endpoint resolvers" $.Resolver }} {{- end }} {{ define "partition consts" }} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/errors.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/errors.go index 57663616..fa06f7a8 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/errors.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/errors.go @@ -5,13 +5,9 @@ import "github.com/aws/aws-sdk-go/aws/awserr" var ( // ErrMissingRegion is an error that is returned if region configuration is // not found. - // - // @readonly ErrMissingRegion = awserr.New("MissingRegion", "could not find region configuration", nil) // ErrMissingEndpoint is an error that is returned if an endpoint cannot be // resolved for a service. - // - // @readonly ErrMissingEndpoint = awserr.New("MissingEndpoint", "'Endpoint' configuration is required for this service", nil) ) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go index 605a72d3..8ef8548a 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/handlers.go @@ -19,6 +19,7 @@ type Handlers struct { UnmarshalError HandlerList Retry HandlerList AfterRetry HandlerList + CompleteAttempt HandlerList Complete HandlerList } @@ -36,6 +37,7 @@ func (h *Handlers) Copy() Handlers { UnmarshalMeta: h.UnmarshalMeta.copy(), Retry: h.Retry.copy(), AfterRetry: h.AfterRetry.copy(), + CompleteAttempt: h.CompleteAttempt.copy(), Complete: h.Complete.copy(), } } @@ -53,6 +55,7 @@ func (h *Handlers) Clear() { h.ValidateResponse.Clear() h.Retry.Clear() h.AfterRetry.Clear() + h.CompleteAttempt.Clear() h.Complete.Clear() } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/request.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/request.go index 75f0fe07..8f2eb3e4 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/request.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/request.go @@ -4,7 +4,6 @@ import ( "bytes" "fmt" "io" - "net" "net/http" "net/url" "reflect" @@ -122,7 +121,6 @@ func New(cfg aws.Config, clientInfo metadata.ClientInfo, handlers Handlers, Handlers: handlers.Copy(), Retryer: retryer, - AttemptTime: time.Now(), Time: time.Now(), ExpireTime: 0, Operation: operation, @@ -266,7 +264,9 @@ func (r *Request) SetReaderBody(reader io.ReadSeeker) { } // Presign returns the request's signed URL. Error will be returned -// if the signing fails. +// if the signing fails. The expire parameter is only used for presigned Amazon +// S3 API requests. All other AWS services will use a fixed expiration +// time of 15 minutes. // // It is invalid to create a presigned URL with a expire duration 0 or less. An // error is returned if expire duration is 0 or less. @@ -283,7 +283,9 @@ func (r *Request) Presign(expire time.Duration) (string, error) { } // PresignRequest behaves just like presign, with the addition of returning a -// set of headers that were signed. +// set of headers that were signed. The expire parameter is only used for +// presigned Amazon S3 API requests. All other AWS services will use a fixed +// expiration time of 15 minutes. // // It is invalid to create a presigned URL with a expire duration 0 or less. An // error is returned if expire duration is 0 or less. @@ -462,80 +464,78 @@ func (r *Request) Send() error { r.Handlers.Complete.Run(r) }() + if err := r.Error; err != nil { + return err + } + for { + r.Error = nil r.AttemptTime = time.Now() - if aws.BoolValue(r.Retryable) { - if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) { - r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d", - r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount)) - } - - // The previous http.Request will have a reference to the r.Body - // and the HTTP Client's Transport may still be reading from - // the request's body even though the Client's Do returned. - r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil) - r.ResetBody() - - // Closing response body to ensure that no response body is leaked - // between retry attempts. - if r.HTTPResponse != nil && r.HTTPResponse.Body != nil { - r.HTTPResponse.Body.Close() - } - } - r.Sign() - if r.Error != nil { - return r.Error + if err := r.Sign(); err != nil { + debugLogReqError(r, "Sign Request", false, err) + return err } - r.Retryable = nil - - r.Handlers.Send.Run(r) - if r.Error != nil { - if !shouldRetryCancel(r) { - return r.Error - } - - err := r.Error + if err := r.sendRequest(); err == nil { + return nil + } else if !shouldRetryCancel(r.Error) { + return err + } else { r.Handlers.Retry.Run(r) r.Handlers.AfterRetry.Run(r) - if r.Error != nil { - debugLogReqError(r, "Send Request", false, err) - return r.Error - } - debugLogReqError(r, "Send Request", true, err) - continue - } - r.Handlers.UnmarshalMeta.Run(r) - r.Handlers.ValidateResponse.Run(r) - if r.Error != nil { - r.Handlers.UnmarshalError.Run(r) - err := r.Error - r.Handlers.Retry.Run(r) - r.Handlers.AfterRetry.Run(r) - if r.Error != nil { - debugLogReqError(r, "Validate Response", false, err) + if r.Error != nil || !aws.BoolValue(r.Retryable) { return r.Error } - debugLogReqError(r, "Validate Response", true, err) - continue - } - r.Handlers.Unmarshal.Run(r) - if r.Error != nil { - err := r.Error - r.Handlers.Retry.Run(r) - r.Handlers.AfterRetry.Run(r) - if r.Error != nil { - debugLogReqError(r, "Unmarshal Response", false, err) - return r.Error - } - debugLogReqError(r, "Unmarshal Response", true, err) + r.prepareRetry() continue } + } +} + +func (r *Request) prepareRetry() { + if r.Config.LogLevel.Matches(aws.LogDebugWithRequestRetries) { + r.Config.Logger.Log(fmt.Sprintf("DEBUG: Retrying Request %s/%s, attempt %d", + r.ClientInfo.ServiceName, r.Operation.Name, r.RetryCount)) + } + + // The previous http.Request will have a reference to the r.Body + // and the HTTP Client's Transport may still be reading from + // the request's body even though the Client's Do returned. + r.HTTPRequest = copyHTTPRequest(r.HTTPRequest, nil) + r.ResetBody() + + // Closing response body to ensure that no response body is leaked + // between retry attempts. + if r.HTTPResponse != nil && r.HTTPResponse.Body != nil { + r.HTTPResponse.Body.Close() + } +} + +func (r *Request) sendRequest() (sendErr error) { + defer r.Handlers.CompleteAttempt.Run(r) + + r.Retryable = nil + r.Handlers.Send.Run(r) + if r.Error != nil { + debugLogReqError(r, "Send Request", r.WillRetry(), r.Error) + return r.Error + } - break + r.Handlers.UnmarshalMeta.Run(r) + r.Handlers.ValidateResponse.Run(r) + if r.Error != nil { + r.Handlers.UnmarshalError.Run(r) + debugLogReqError(r, "Validate Response", r.WillRetry(), r.Error) + return r.Error + } + + r.Handlers.Unmarshal.Run(r) + if r.Error != nil { + debugLogReqError(r, "Unmarshal Response", r.WillRetry(), r.Error) + return r.Error } return nil @@ -561,30 +561,46 @@ func AddToUserAgent(r *Request, s string) { r.HTTPRequest.Header.Set("User-Agent", s) } -func shouldRetryCancel(r *Request) bool { - awsErr, ok := r.Error.(awserr.Error) - timeoutErr := false - errStr := r.Error.Error() - if ok { - if awsErr.Code() == CanceledErrorCode { +type temporary interface { + Temporary() bool +} + +func shouldRetryCancel(err error) bool { + switch err := err.(type) { + case awserr.Error: + if err.Code() == CanceledErrorCode { return false } - err := awsErr.OrigErr() - netErr, netOK := err.(net.Error) - timeoutErr = netOK && netErr.Temporary() - if urlErr, ok := err.(*url.Error); !timeoutErr && ok { - errStr = urlErr.Err.Error() + return shouldRetryCancel(err.OrigErr()) + case *url.Error: + if strings.Contains(err.Error(), "connection refused") { + // Refused connections should be retried as the service may not yet + // be running on the port. Go TCP dial considers refused + // connections as not temporary. + return true + } + // *url.Error only implements Temporary after golang 1.6 but since + // url.Error only wraps the error: + return shouldRetryCancel(err.Err) + case temporary: + // If the error is temporary, we want to allow continuation of the + // retry process + return err.Temporary() + case nil: + // `awserr.Error.OrigErr()` can be nil, meaning there was an error but + // because we don't know the cause, it is marked as retriable. See + // TestRequest4xxUnretryable for an example. + return true + default: + switch err.Error() { + case "net/http: request canceled", + "net/http: request canceled while waiting for connection": + // known 1.5 error case when an http request is cancelled + return false } + // here we don't know the error; so we allow a retry. + return true } - - // There can be two types of canceled errors here. - // The first being a net.Error and the other being an error. - // If the request was timed out, we want to continue the retry - // process. Otherwise, return the canceled error. - return timeoutErr || - (errStr != "net/http: request canceled" && - errStr != "net/http: request canceled while waiting for connection") - } // SanitizeHostForHeader removes default port from host and updates request.Host diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go index 7d527029..7bc5da78 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/retryer.go @@ -40,6 +40,7 @@ var throttleCodes = map[string]struct{}{ "RequestThrottled": {}, "TooManyRequestsException": {}, // Lambda functions "PriorRequestNotComplete": {}, // Route53 + "TransactionInProgressException": {}, } // credsExpiredCodes is a collection of error codes which signify the credentials diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go index bcfd947a..8630683f 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/request/validation.go @@ -17,6 +17,8 @@ const ( ParamMinValueErrCode = "ParamMinValueError" // ParamMinLenErrCode is the error code for fields without enough elements. ParamMinLenErrCode = "ParamMinLenError" + // ParamMaxLenErrCode is the error code for value being too long. + ParamMaxLenErrCode = "ParamMaxLenError" // ParamFormatErrCode is the error code for a field with invalid // format or characters. @@ -237,6 +239,29 @@ func (e *ErrParamMinLen) MinLen() int { return e.min } +// An ErrParamMaxLen represents a maximum length parameter error. +type ErrParamMaxLen struct { + errInvalidParam + max int +} + +// NewErrParamMaxLen creates a new maximum length parameter error. +func NewErrParamMaxLen(field string, max int, value string) *ErrParamMaxLen { + return &ErrParamMaxLen{ + errInvalidParam: errInvalidParam{ + code: ParamMaxLenErrCode, + field: field, + msg: fmt.Sprintf("maximum size of %v, %v", max, value), + }, + max: max, + } +} + +// MaxLen returns the field's required minimum length. +func (e *ErrParamMaxLen) MaxLen() int { + return e.max +} + // An ErrParamFormat represents a invalid format parameter error. type ErrParamFormat struct { errInvalidParam diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go index 98d420fd..38a7b05a 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/doc.go @@ -99,7 +99,7 @@ handler logs every request and its payload made by a service client: sess.Handlers.Send.PushFront(func(r *request.Request) { // Log every request made and its payload - logger.Println("Request: %s/%s, Payload: %s", + logger.Printf("Request: %s/%s, Payload: %s", r.ClientInfo.ServiceName, r.Operation, r.Params) }) @@ -183,7 +183,7 @@ be returned when creating the session. // from assumed role. svc := s3.New(sess) -To setup assume role outside of a session see the stscrds.AssumeRoleProvider +To setup assume role outside of a session see the stscreds.AssumeRoleProvider documentation. Environment Variables diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go index 82e04d76..e3959b95 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/env_config.go @@ -4,6 +4,7 @@ import ( "os" "strconv" + "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/defaults" ) @@ -79,7 +80,7 @@ type envConfig struct { // AWS_CONFIG_FILE=$HOME/my_shared_config SharedConfigFile string - // Sets the path to a custom Credentials Authroity (CA) Bundle PEM file + // Sets the path to a custom Credentials Authority (CA) Bundle PEM file // that the SDK will use instead of the system's root CA bundle. // Only use this if you want to configure the SDK to use a custom set // of CAs. @@ -101,6 +102,12 @@ type envConfig struct { CSMEnabled bool CSMPort string CSMClientID string + + enableEndpointDiscovery string + // Enables endpoint discovery via environment variables. + // + // AWS_ENABLE_ENDPOINT_DISCOVERY=true + EnableEndpointDiscovery *bool } var ( @@ -125,6 +132,10 @@ var ( "AWS_SESSION_TOKEN", } + enableEndpointDiscoveryEnvKey = []string{ + "AWS_ENABLE_ENDPOINT_DISCOVERY", + } + regionEnvKeys = []string{ "AWS_REGION", "AWS_DEFAULT_REGION", // Only read if AWS_SDK_LOAD_CONFIG is also set @@ -194,6 +205,12 @@ func envConfigLoad(enableSharedConfig bool) envConfig { setFromEnvVal(&cfg.Region, regionKeys) setFromEnvVal(&cfg.Profile, profileKeys) + // endpoint discovery is in reference to it being enabled. + setFromEnvVal(&cfg.enableEndpointDiscovery, enableEndpointDiscoveryEnvKey) + if len(cfg.enableEndpointDiscovery) > 0 { + cfg.EnableEndpointDiscovery = aws.Bool(cfg.enableEndpointDiscovery != "false") + } + setFromEnvVal(&cfg.SharedCredentialsFile, sharedCredsFileEnvKey) setFromEnvVal(&cfg.SharedConfigFile, sharedConfigFileEnvKey) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/session.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/session.go index 5d7b2895..9bdbafd6 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/session.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/session.go @@ -14,6 +14,7 @@ import ( "github.com/aws/aws-sdk-go/aws/client" "github.com/aws/aws-sdk-go/aws/corehandlers" "github.com/aws/aws-sdk-go/aws/credentials" + "github.com/aws/aws-sdk-go/aws/credentials/processcreds" "github.com/aws/aws-sdk-go/aws/credentials/stscreds" "github.com/aws/aws-sdk-go/aws/csm" "github.com/aws/aws-sdk-go/aws/defaults" @@ -452,6 +453,14 @@ func mergeConfigSrcs(cfg, userCfg *aws.Config, envCfg envConfig, sharedCfg share } } + if cfg.EnableEndpointDiscovery == nil { + if envCfg.EnableEndpointDiscovery != nil { + cfg.WithEndpointDiscovery(*envCfg.EnableEndpointDiscovery) + } else if envCfg.EnableSharedConfig && sharedCfg.EnableEndpointDiscovery != nil { + cfg.WithEndpointDiscovery(*sharedCfg.EnableEndpointDiscovery) + } + } + // Configure credentials if not already set if cfg.Credentials == credentials.AnonymousCredentials && userCfg.Credentials == nil { @@ -526,6 +535,10 @@ func mergeConfigSrcs(cfg, userCfg *aws.Config, envCfg envConfig, sharedCfg share cfg.Credentials = credentials.NewStaticCredentialsFromCreds( sharedCfg.Creds, ) + } else if len(sharedCfg.CredentialProcess) > 0 { + cfg.Credentials = processcreds.NewCredentials( + sharedCfg.CredentialProcess, + ) } else { // Fallback to default credentials provider, include mock errors // for the credential chain so user can identify why credentials diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go index efe17ed3..7cb44021 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/session/shared_config.go @@ -26,6 +26,11 @@ const ( // Additional Config fields regionKey = `region` + // endpoint discovery group + enableEndpointDiscoveryKey = `endpoint_discovery_enabled` // optional + // External Credential Process + credentialProcessKey = `credential_process` + // DefaultSharedConfigProfile is the default profile to be used when // loading configuration from the config files if another profile name // is not provided. @@ -57,11 +62,20 @@ type sharedConfig struct { AssumeRole assumeRoleConfig AssumeRoleSource *sharedConfig + // An external process to request credentials + CredentialProcess string + // Region is the region the SDK should use for looking up AWS service endpoints // and signing requests. // // region Region string + + // EnableEndpointDiscovery can be enabled in the shared config by setting + // endpoint_discovery_enabled to true + // + // endpoint_discovery_enabled = true + EnableEndpointDiscovery *bool } type sharedConfigFile struct { @@ -214,11 +228,22 @@ func (cfg *sharedConfig) setFromIniFile(profile string, file sharedConfigFile) e } } + // `credential_process` + if credProc := section.String(credentialProcessKey); len(credProc) > 0 { + cfg.CredentialProcess = credProc + } + // Region if v := section.String(regionKey); len(v) > 0 { cfg.Region = v } + // Endpoint discovery + if section.Has(enableEndpointDiscoveryKey) { + v := section.Bool(enableEndpointDiscoveryKey) + cfg.EnableEndpointDiscovery = &v + } + return nil } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go index 5b52ab22..523db79f 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/signer/v4/v4.go @@ -98,25 +98,25 @@ var ignoredHeaders = rules{ var requiredSignedHeaders = rules{ whitelist{ mapRule{ - "Cache-Control": struct{}{}, - "Content-Disposition": struct{}{}, - "Content-Encoding": struct{}{}, - "Content-Language": struct{}{}, - "Content-Md5": struct{}{}, - "Content-Type": struct{}{}, - "Expires": struct{}{}, - "If-Match": struct{}{}, - "If-Modified-Since": struct{}{}, - "If-None-Match": struct{}{}, - "If-Unmodified-Since": struct{}{}, - "Range": struct{}{}, - "X-Amz-Acl": struct{}{}, - "X-Amz-Copy-Source": struct{}{}, - "X-Amz-Copy-Source-If-Match": struct{}{}, - "X-Amz-Copy-Source-If-Modified-Since": struct{}{}, - "X-Amz-Copy-Source-If-None-Match": struct{}{}, - "X-Amz-Copy-Source-If-Unmodified-Since": struct{}{}, - "X-Amz-Copy-Source-Range": struct{}{}, + "Cache-Control": struct{}{}, + "Content-Disposition": struct{}{}, + "Content-Encoding": struct{}{}, + "Content-Language": struct{}{}, + "Content-Md5": struct{}{}, + "Content-Type": struct{}{}, + "Expires": struct{}{}, + "If-Match": struct{}{}, + "If-Modified-Since": struct{}{}, + "If-None-Match": struct{}{}, + "If-Unmodified-Since": struct{}{}, + "Range": struct{}{}, + "X-Amz-Acl": struct{}{}, + "X-Amz-Copy-Source": struct{}{}, + "X-Amz-Copy-Source-If-Match": struct{}{}, + "X-Amz-Copy-Source-If-Modified-Since": struct{}{}, + "X-Amz-Copy-Source-If-None-Match": struct{}{}, + "X-Amz-Copy-Source-If-Unmodified-Since": struct{}{}, + "X-Amz-Copy-Source-Range": struct{}{}, "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Algorithm": struct{}{}, "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Key": struct{}{}, "X-Amz-Copy-Source-Server-Side-Encryption-Customer-Key-Md5": struct{}{}, @@ -134,6 +134,7 @@ var requiredSignedHeaders = rules{ "X-Amz-Server-Side-Encryption-Customer-Key": struct{}{}, "X-Amz-Server-Side-Encryption-Customer-Key-Md5": struct{}{}, "X-Amz-Storage-Class": struct{}{}, + "X-Amz-Tagging": struct{}{}, "X-Amz-Website-Redirect-Location": struct{}{}, "X-Amz-Content-Sha256": struct{}{}, }, @@ -181,7 +182,7 @@ type Signer struct { // http://docs.aws.amazon.com/general/latest/gr/sigv4-create-canonical-request.html DisableURIPathEscaping bool - // Disales the automatical setting of the HTTP request's Body field with the + // Disables the automatical setting of the HTTP request's Body field with the // io.ReadSeeker passed in to the signer. This is useful if you're using a // custom wrapper around the body for the io.ReadSeeker and want to preserve // the Body value on the Request.Body. @@ -421,7 +422,7 @@ var SignRequestHandler = request.NamedHandler{ // If the credentials of the request's config are set to // credentials.AnonymousCredentials the request will not be signed. func SignSDKRequest(req *request.Request) { - signSDKRequestWithCurrTime(req, time.Now) + SignSDKRequestWithCurrentTime(req, time.Now) } // BuildNamedHandler will build a generic handler for signing. @@ -429,12 +430,15 @@ func BuildNamedHandler(name string, opts ...func(*Signer)) request.NamedHandler return request.NamedHandler{ Name: name, Fn: func(req *request.Request) { - signSDKRequestWithCurrTime(req, time.Now, opts...) + SignSDKRequestWithCurrentTime(req, time.Now, opts...) }, } } -func signSDKRequestWithCurrTime(req *request.Request, curTimeFn func() time.Time, opts ...func(*Signer)) { +// SignSDKRequestWithCurrentTime will sign the SDK's request using the time +// function passed in. Behaves the same as SignSDKRequest with the exception +// the request is signed with the value returned by the current time function. +func SignSDKRequestWithCurrentTime(req *request.Request, curTimeFn func() time.Time, opts ...func(*Signer)) { // If the request does not need to be signed ignore the signing of the // request if the AnonymousCredentials object is used. if req.Config.Credentials == credentials.AnonymousCredentials { @@ -470,13 +474,9 @@ func signSDKRequestWithCurrTime(req *request.Request, curTimeFn func() time.Time opt(v4) } - signingTime := req.Time - if !req.LastSignedAt.IsZero() { - signingTime = req.LastSignedAt - } - + curTime := curTimeFn() signedHeaders, err := v4.signWithBody(req.HTTPRequest, req.GetBody(), - name, region, req.ExpireTime, req.ExpireTime > 0, signingTime, + name, region, req.ExpireTime, req.ExpireTime > 0, curTime, ) if err != nil { req.Error = err @@ -485,7 +485,7 @@ func signSDKRequestWithCurrTime(req *request.Request, curTimeFn func() time.Time } req.SignedHeaderVals = signedHeaders - req.LastSignedAt = curTimeFn() + req.LastSignedAt = curTime } const logSignInfoMsg = `DEBUG: Request Signature: @@ -754,7 +754,7 @@ func makeSha256Reader(reader io.ReadSeeker) []byte { const doubleSpace = " " // stripExcessSpaces will rewrite the passed in slice's string values to not -// contain muliple side-by-side spaces. +// contain multiple side-by-side spaces. func stripExcessSpaces(vals []string) { var j, k, l, m, spaces int for i, str := range vals { diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/version.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/version.go index bd13d930..000c839b 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/version.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.15.64" +const SDKVersion = "1.16.26" diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go index 8d03fd3d..0b76999b 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/comment_token.go @@ -12,10 +12,6 @@ func isComment(b []rune) bool { return true case '#': return true - case '/': - if len(b) > 1 { - return b[1] == '/' - } } return false diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go index 445b503c..25ce0fe1 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/doc.go @@ -24,7 +24,6 @@ // // SkipState will skip (NL WS)+ // -// comment -> # comment' | ; comment' | / comment_slash -// comment_slash -> / comment' +// comment -> # comment' | ; comment' // comment' -> epsilon | value package ini diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go index 3bf43902..f9970337 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/ini_parser.go @@ -25,8 +25,7 @@ const ( // SkipTokenState will skip any token and push the previous // state onto the stack. SkipTokenState - // comment -> # comment' | ; comment' | / comment_slash - // comment_slash -> / comment' + // comment -> # comment' | ; comment' // comment' -> MarkComplete | value CommentState // MarkComplete state will complete statements and move that @@ -58,7 +57,7 @@ var parseTable = map[ASTKind]map[TokenType]int{ TokenOp: StatementPrimeState, TokenLit: ValueState, TokenSep: OpenScopeState, - TokenWS: SkipTokenState, + TokenWS: ValueState, TokenNL: SkipState, TokenComment: CommentState, TokenNone: MarkCompleteState, @@ -88,8 +87,9 @@ var parseTable = map[ASTKind]map[TokenType]int{ }, ASTKindSectionStatement: map[TokenType]int{ TokenLit: SectionState, + TokenOp: SectionState, TokenSep: CloseScopeState, - TokenWS: SkipTokenState, + TokenWS: SectionState, TokenNL: SkipTokenState, }, ASTKindCompletedSectionStatement: map[TokenType]int{ @@ -157,6 +157,12 @@ loop: step := parseTable[k.Kind][tok.Type()] if s.ShouldSkip(tok) { + // being in a skip state with no tokens will break out of + // the parse loop since there is nothing left to process. + if len(tokens) == 0 { + break loop + } + step = SkipTokenState } @@ -192,6 +198,7 @@ loop: ) } + k = trimSpaces(k) expr := newEqualExpr(k, tok) stack.Push(expr) case ValueState: @@ -214,6 +221,9 @@ loop: // assiging a value to some key k.AppendChild(newExpression(tok)) stack.Push(newExprStatement(k)) + case ASTKindExpr: + k.Root.raw = append(k.Root.raw, tok.Raw()...) + stack.Push(k) case ASTKindExprStatement: root := k.GetRoot() children := root.GetChildren() @@ -248,6 +258,7 @@ loop: return nil, NewParseError("expected ']'") } + k = trimSpaces(k) stack.Push(newCompletedSectionStatement(k)) case SectionState: var stmt AST @@ -263,7 +274,6 @@ loop: // the label of the section stmt = newSectionStatement(tok) case ASTKindSectionStatement: - k.Root.raw = append(k.Root.raw, ' ') k.Root.raw = append(k.Root.raw, tok.Raw()...) stmt = k default: @@ -307,6 +317,31 @@ loop: return nil, NewParseError(fmt.Sprintf("incomplete expression: %v", stack.container)) } - // returns a sublist which exludes the start symbol + // returns a sublist which excludes the start symbol return stack.List(), nil } + +// trimSpaces will trim spaces on the left and right hand side of +// the literal. +func trimSpaces(k AST) AST { + // trim left hand side of spaces + for i := 0; i < len(k.Root.raw); i++ { + if !isWhitespace(k.Root.raw[i]) { + break + } + + k.Root.raw = k.Root.raw[1:] + i-- + } + + // trim right hand side of spaces + for i := len(k.Root.raw) - 1; i >= 0; i-- { + if !isWhitespace(k.Root.raw[i]) { + break + } + + k.Root.raw = k.Root.raw[:len(k.Root.raw)-1] + } + + return k +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go index 61754c88..24df543d 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/literal_tokens.go @@ -166,9 +166,6 @@ func newValue(t ValueType, base int, raw []rune) (Value, error) { switch t { case DecimalType: v.decimal, err = strconv.ParseFloat(string(raw), 64) - if err != nil { - panic(err) - } case IntegerType: if base != 10 { raw = raw[2:] @@ -183,6 +180,16 @@ func newValue(t ValueType, base int, raw []rune) (Value, error) { v.boolean = runeCompare(v.raw, runesTrue) } + // issue 2253 + // + // if the value trying to be parsed is too large, then we will use + // the 'StringType' and raw value instead. + if nerr, ok := err.(*strconv.NumError); ok && nerr.Err == strconv.ErrRange { + v.Type = StringType + v.str = string(raw) + err = nil + } + return v, err } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go index b72ea2fc..6bb69644 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/skipper.go @@ -5,10 +5,10 @@ package ini // files. See example below // // [ foo ] -// nested = // this section will be skipped +// nested = ; this section will be skipped // a=b // c=d -// bar=baz // this will be included +// bar=baz ; this will be included type skipper struct { shouldSkip bool TokenSet bool @@ -22,7 +22,10 @@ func newSkipper() skipper { } func (s *skipper) ShouldSkip(tok Token) bool { - if s.shouldSkip && s.prevTok.Type() == TokenNL && tok.Type() != TokenWS { + if s.shouldSkip && + s.prevTok.Type() == TokenNL && + tok.Type() != TokenWS { + s.Continue() return false } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go index ea86fea8..18f3fe89 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/statement.go @@ -15,12 +15,11 @@ func newExprStatement(ast AST) AST { return newAST(ASTKindExprStatement, ast) } -// CommentStatement represents a comment in the ini defintion. +// CommentStatement represents a comment in the ini definition. // // grammar: -// comment -> #comment' | ;comment' | /comment_slash -// comment_slash -> /comment' -// comment' -> value +// comment -> #comment' | ;comment' +// comment' -> epsilon | value func newCommentStatement(tok Token) AST { return newAST(ASTKindCommentStatement, newExpression(tok)) } diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go index 99d4f19b..94841c32 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/ini/visitor.go @@ -141,6 +141,11 @@ func (t Section) ValueType(k string) (ValueType, bool) { return v.Type, ok } +// Bool returns a bool value at k +func (t Section) Bool(k string) bool { + return t.values[k].BoolValue() +} + // Int returns an integer value at k func (t Section) Int(k string) int64 { return t.values[k].IntValue() diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go index b63e4c26..7da8a49c 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/internal/shareddefaults/ecs_container.go @@ -7,6 +7,6 @@ const ( ) // ECSContainerCredentialsURI is the endpoint to retrieve container -// credentials. This can be overriden to test to ensure the credential process +// credentials. This can be overridden to test to ensure the credential process // is behaving correctly. var ECSContainerCredentialsURI = "http://169.254.170.2" diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go index f06f44ee..d7d42db0 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host.go @@ -1,7 +1,54 @@ package protocol -// ValidHostLabel returns if the label is a valid RFC 1123 Section 2.1 domain -// host label name. +import ( + "strings" + + "github.com/aws/aws-sdk-go/aws/request" +) + +// ValidateEndpointHostHandler is a request handler that will validate the +// request endpoint's hosts is a valid RFC 3986 host. +var ValidateEndpointHostHandler = request.NamedHandler{ + Name: "awssdk.protocol.ValidateEndpointHostHandler", + Fn: func(r *request.Request) { + err := ValidateEndpointHost(r.Operation.Name, r.HTTPRequest.URL.Host) + if err != nil { + r.Error = err + } + }, +} + +// ValidateEndpointHost validates that the host string passed in is a valid RFC +// 3986 host. Returns error if the host is not valid. +func ValidateEndpointHost(opName, host string) error { + paramErrs := request.ErrInvalidParams{Context: opName} + labels := strings.Split(host, ".") + + for i, label := range labels { + if i == len(labels)-1 && len(label) == 0 { + // Allow trailing dot for FQDN hosts. + continue + } + + if !ValidHostLabel(label) { + paramErrs.Add(request.NewErrParamFormat( + "endpoint host label", "[a-zA-Z0-9-]{1,63}", label)) + } + } + + if len(host) > 255 { + paramErrs.Add(request.NewErrParamMaxLen( + "endpoint host", 255, host, + )) + } + + if paramErrs.Len() > 0 { + return paramErrs + } + return nil +} + +// ValidHostLabel returns if the label is a valid RFC 3986 host label. func ValidHostLabel(label string) bool { if l := len(label); l == 0 || l > 63 { return false diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go new file mode 100644 index 00000000..915b0fca --- /dev/null +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/host_prefix.go @@ -0,0 +1,54 @@ +package protocol + +import ( + "strings" + + "github.com/aws/aws-sdk-go/aws" + "github.com/aws/aws-sdk-go/aws/request" +) + +// HostPrefixHandlerName is the handler name for the host prefix request +// handler. +const HostPrefixHandlerName = "awssdk.endpoint.HostPrefixHandler" + +// NewHostPrefixHandler constructs a build handler +func NewHostPrefixHandler(prefix string, labelsFn func() map[string]string) request.NamedHandler { + builder := HostPrefixBuilder{ + Prefix: prefix, + LabelsFn: labelsFn, + } + + return request.NamedHandler{ + Name: HostPrefixHandlerName, + Fn: builder.Build, + } +} + +// HostPrefixBuilder provides the request handler to expand and prepend +// the host prefix into the operation's request endpoint host. +type HostPrefixBuilder struct { + Prefix string + LabelsFn func() map[string]string +} + +// Build updates the passed in Request with the HostPrefix template expanded. +func (h HostPrefixBuilder) Build(r *request.Request) { + if aws.BoolValue(r.Config.DisableEndpointHostPrefix) { + return + } + + var labels map[string]string + if h.LabelsFn != nil { + labels = h.LabelsFn() + } + + prefix := h.Prefix + for name, value := range labels { + prefix = strings.Replace(prefix, "{"+name+"}", value, -1) + } + + r.HTTPRequest.URL.Host = prefix + r.HTTPRequest.URL.Host + if len(r.HTTPRequest.Host) > 0 { + r.HTTPRequest.Host = prefix + r.HTTPRequest.Host + } +} diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go index 1bfe45f6..cf981fe9 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/private/protocol/xml/xmlutil/build.go @@ -87,7 +87,7 @@ func (b *xmlBuilder) buildValue(value reflect.Value, current *XMLNode, tag refle } } -// buildStruct adds a struct and its fields to the current XMLNode. All fields any any nested +// buildStruct adds a struct and its fields to the current XMLNode. All fields and any nested // types are converted to XMLNodes also. func (b *xmlBuilder) buildStruct(value reflect.Value, current *XMLNode, tag reflect.StructTag) error { if !value.IsValid() { diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go index ef61f6e8..e3284308 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/api.go @@ -8,6 +8,8 @@ import ( "github.com/aws/aws-sdk-go/aws" "github.com/aws/aws-sdk-go/aws/awsutil" "github.com/aws/aws-sdk-go/aws/request" + "github.com/aws/aws-sdk-go/private/protocol" + "github.com/aws/aws-sdk-go/private/protocol/jsonrpc" ) const opBatchCheckLayerAvailability = "BatchCheckLayerAvailability" @@ -456,6 +458,15 @@ func (c *ECR) CreateRepositoryRequest(input *CreateRepositoryInput) (req *reques // The specified parameter is invalid. Review the available parameters for the // API request. // +// * ErrCodeInvalidTagParameterException "InvalidTagParameterException" +// An invalid parameter has been specified. Tag keys can have a maximum character +// length of 128 characters, and tag values can have a maximum length of 256 +// characters. +// +// * ErrCodeTooManyTagsException "TooManyTagsException" +// The list of tags on the repository is over the limit. The maximum number +// of tags that can be applied to a repository is 50. +// // * ErrCodeRepositoryAlreadyExistsException "RepositoryAlreadyExistsException" // The specified repository already exists in the specified registry. // @@ -1756,6 +1767,93 @@ func (c *ECR) ListImagesPagesWithContext(ctx aws.Context, input *ListImagesInput return p.Err() } +const opListTagsForResource = "ListTagsForResource" + +// ListTagsForResourceRequest generates a "aws/request.Request" representing the +// client's request for the ListTagsForResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See ListTagsForResource for more information on using the ListTagsForResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the ListTagsForResourceRequest method. +// req, resp := client.ListTagsForResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ListTagsForResource +func (c *ECR) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { + op := &request.Operation{ + Name: opListTagsForResource, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &ListTagsForResourceInput{} + } + + output = &ListTagsForResourceOutput{} + req = c.newRequest(op, input, output) + return +} + +// ListTagsForResource API operation for Amazon EC2 Container Registry. +// +// List the tags for an Amazon ECR resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon EC2 Container Registry's +// API operation ListTagsForResource for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterException "InvalidParameterException" +// The specified parameter is invalid. Review the available parameters for the +// API request. +// +// * ErrCodeRepositoryNotFoundException "RepositoryNotFoundException" +// The specified repository could not be found. Check the spelling of the specified +// repository and ensure that you are performing operations on the correct registry. +// +// * ErrCodeServerException "ServerException" +// These errors are usually caused by a server-side issue. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/ListTagsForResource +func (c *ECR) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + return out, req.Send() +} + +// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// the ability to pass a context and additional request options. +// +// See ListTagsForResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ECR) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opPutImage = "PutImage" // PutImageRequest generates a "aws/request.Request" representing the @@ -2131,6 +2229,201 @@ func (c *ECR) StartLifecyclePolicyPreviewWithContext(ctx aws.Context, input *Sta return out, req.Send() } +const opTagResource = "TagResource" + +// TagResourceRequest generates a "aws/request.Request" representing the +// client's request for the TagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See TagResource for more information on using the TagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the TagResourceRequest method. +// req, resp := client.TagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/TagResource +func (c *ECR) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { + op := &request.Operation{ + Name: opTagResource, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &TagResourceInput{} + } + + output = &TagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// TagResource API operation for Amazon EC2 Container Registry. +// +// Adds specified tags to a resource with the specified ARN. Existing tags on +// a resource are not changed if they are not specified in the request parameters. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon EC2 Container Registry's +// API operation TagResource for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterException "InvalidParameterException" +// The specified parameter is invalid. Review the available parameters for the +// API request. +// +// * ErrCodeInvalidTagParameterException "InvalidTagParameterException" +// An invalid parameter has been specified. Tag keys can have a maximum character +// length of 128 characters, and tag values can have a maximum length of 256 +// characters. +// +// * ErrCodeTooManyTagsException "TooManyTagsException" +// The list of tags on the repository is over the limit. The maximum number +// of tags that can be applied to a repository is 50. +// +// * ErrCodeRepositoryNotFoundException "RepositoryNotFoundException" +// The specified repository could not be found. Check the spelling of the specified +// repository and ensure that you are performing operations on the correct registry. +// +// * ErrCodeServerException "ServerException" +// These errors are usually caused by a server-side issue. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/TagResource +func (c *ECR) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + return out, req.Send() +} + +// TagResourceWithContext is the same as TagResource with the addition of +// the ability to pass a context and additional request options. +// +// See TagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ECR) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUntagResource = "UntagResource" + +// UntagResourceRequest generates a "aws/request.Request" representing the +// client's request for the UntagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UntagResource for more information on using the UntagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// +// // Example sending a request using the UntagResourceRequest method. +// req, resp := client.UntagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UntagResource +func (c *ECR) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { + op := &request.Operation{ + Name: opUntagResource, + HTTPMethod: "POST", + HTTPPath: "/", + } + + if input == nil { + input = &UntagResourceInput{} + } + + output = &UntagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// UntagResource API operation for Amazon EC2 Container Registry. +// +// Deletes specified tags from a resource. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for Amazon EC2 Container Registry's +// API operation UntagResource for usage and error information. +// +// Returned Error Codes: +// * ErrCodeInvalidParameterException "InvalidParameterException" +// The specified parameter is invalid. Review the available parameters for the +// API request. +// +// * ErrCodeInvalidTagParameterException "InvalidTagParameterException" +// An invalid parameter has been specified. Tag keys can have a maximum character +// length of 128 characters, and tag values can have a maximum length of 256 +// characters. +// +// * ErrCodeTooManyTagsException "TooManyTagsException" +// The list of tags on the repository is over the limit. The maximum number +// of tags that can be applied to a repository is 50. +// +// * ErrCodeRepositoryNotFoundException "RepositoryNotFoundException" +// The specified repository could not be found. Check the spelling of the specified +// repository and ensure that you are performing operations on the correct registry. +// +// * ErrCodeServerException "ServerException" +// These errors are usually caused by a server-side issue. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/ecr-2015-09-21/UntagResource +func (c *ECR) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + return out, req.Send() +} + +// UntagResourceWithContext is the same as UntagResource with the addition of +// the ability to pass a context and additional request options. +// +// See UntagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *ECR) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opUploadLayerPart = "UploadLayerPart" // UploadLayerPartRequest generates a "aws/request.Request" representing the @@ -2745,6 +3038,8 @@ type CreateRepositoryInput struct { // // RepositoryName is a required field RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"` + + Tags []*Tag `locationName:"tags" type:"list"` } // String returns the string representation @@ -2779,6 +3074,12 @@ func (s *CreateRepositoryInput) SetRepositoryName(v string) *CreateRepositoryInp return s } +// SetTags sets the Tags field's value. +func (s *CreateRepositoryInput) SetTags(v []*Tag) *CreateRepositoryInput { + s.Tags = v + return s +} + type CreateRepositoryOutput struct { _ struct{} `type:"structure"` @@ -3119,7 +3420,7 @@ type DescribeImagesInput struct { // results in a single page along with a nextToken response element. The remaining // results of the initial request can be seen by sending another DescribeImages // request with the returned nextToken value. This value can be between 1 and - // 100. If this parameter is not used, then DescribeImages returns up to 100 + // 1000. If this parameter is not used, then DescribeImages returns up to 100 // results and a nextToken value, if applicable. This option cannot be used // when you specify images with imageIds. MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` @@ -3136,8 +3437,7 @@ type DescribeImagesInput struct { // registry is assumed. RegistryId *string `locationName:"registryId" type:"string"` - // A list of repositories to describe. If this parameter is omitted, then all - // repositories in a registry are described. + // A list of repositories to describe. // // RepositoryName is a required field RepositoryName *string `locationName:"repositoryName" min:"2" type:"string" required:"true"` @@ -3254,7 +3554,7 @@ type DescribeRepositoriesInput struct { // returns maxResults results in a single page along with a nextToken response // element. The remaining results of the initial request can be seen by sending // another DescribeRepositories request with the returned nextToken value. This - // value can be between 1 and 100. If this parameter is not used, then DescribeRepositories + // value can be between 1 and 1000. If this parameter is not used, then DescribeRepositories // returns up to 100 results and a nextToken value, if applicable. This option // cannot be used when you specify repositories with repositoryNames. MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` @@ -3640,7 +3940,7 @@ type GetLifecyclePolicyPreviewInput struct { // only returns
 maxResults results in a single page along with a nextToken // response element. The remaining results of the initial request can be seen // by sending
 another GetLifecyclePolicyPreviewRequest request with the returned - // nextToken
 value. This value can be between 1 and 100. If this
 parameter + // nextToken
 value. This value can be between 1 and 1000. If this
 parameter // is not used, then GetLifecyclePolicyPreviewRequest returns up to
 100 results // and a nextToken value, if
 applicable. This option cannot be used when you // specify images with imageIds. @@ -4452,9 +4752,9 @@ type ListImagesInput struct { // When this parameter is used, ListImages only returns maxResults results in // a single page along with a nextToken response element. The remaining results // of the initial request can be seen by sending another ListImages request - // with the returned nextToken value. This value can be between 1 and 100. If - // this parameter is not used, then ListImages returns up to 100 results and - // a nextToken value, if applicable. + // with the returned nextToken value. This value can be between 1 and 1000. + // If this parameter is not used, then ListImages returns up to 100 results + // and a nextToken value, if applicable. MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` // The nextToken value returned from a previous paginated ListImages request @@ -4571,6 +4871,68 @@ func (s *ListImagesOutput) SetNextToken(v string) *ListImagesOutput { return s } +type ListTagsForResourceInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) that identifies the resource for which to + // list the tags. Currently, the only supported resource is an Amazon ECR repository. + // + // ResourceArn is a required field + ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"` +} + +// String returns the string representation +func (s ListTagsForResourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListTagsForResourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListTagsForResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { + s.ResourceArn = &v + return s +} + +type ListTagsForResourceOutput struct { + _ struct{} `type:"structure"` + + // The tags for the resource. + Tags []*Tag `locationName:"tags" type:"list"` +} + +// String returns the string representation +func (s ListTagsForResourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s ListTagsForResourceOutput) GoString() string { + return s.String() +} + +// SetTags sets the Tags field's value. +func (s *ListTagsForResourceOutput) SetTags(v []*Tag) *ListTagsForResourceOutput { + s.Tags = v + return s +} + type PutImageInput struct { _ struct{} `type:"structure"` @@ -5074,6 +5436,180 @@ func (s *StartLifecyclePolicyPreviewOutput) SetStatus(v string) *StartLifecycleP return s } +// The metadata that you apply to a resource to help you categorize and organize +// them. Each tag consists of a key and an optional value, both of which you +// define. Tag keys can have a maximum character length of 128 characters, and +// tag values can have a maximum length of 256 characters. +type Tag struct { + _ struct{} `type:"structure"` + + // One part of a key-value pair that make up a tag. A key is a general label + // that acts like a category for more specific tag values. + Key *string `type:"string"` + + // The optional part of a key-value pair that make up a tag. A value acts as + // a descriptor within a tag category (key). + Value *string `type:"string"` +} + +// String returns the string representation +func (s Tag) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s Tag) GoString() string { + return s.String() +} + +// SetKey sets the Key field's value. +func (s *Tag) SetKey(v string) *Tag { + s.Key = &v + return s +} + +// SetValue sets the Value field's value. +func (s *Tag) SetValue(v string) *Tag { + s.Value = &v + return s +} + +type TagResourceInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the the resource to which to add tags. + // Currently, the only supported resource is an Amazon ECR repository. + // + // ResourceArn is a required field + ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"` + + // The tags to add to the resource. A tag is an array of key-value pairs. Tag + // keys can have a maximum character length of 128 characters, and tag values + // can have a maximum length of 256 characters. + // + // Tags is a required field + Tags []*Tag `locationName:"tags" type:"list" required:"true"` +} + +// String returns the string representation +func (s TagResourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s TagResourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *TagResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "TagResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.Tags == nil { + invalidParams.Add(request.NewErrParamRequired("Tags")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *TagResourceInput) SetResourceArn(v string) *TagResourceInput { + s.ResourceArn = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *TagResourceInput) SetTags(v []*Tag) *TagResourceInput { + s.Tags = v + return s +} + +type TagResourceOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s TagResourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s TagResourceOutput) GoString() string { + return s.String() +} + +type UntagResourceInput struct { + _ struct{} `type:"structure"` + + // The Amazon Resource Name (ARN) of the resource from which to remove tags. + // Currently, the only supported resource is an Amazon ECR repository. + // + // ResourceArn is a required field + ResourceArn *string `locationName:"resourceArn" type:"string" required:"true"` + + // The keys of the tags to be removed. + // + // TagKeys is a required field + TagKeys []*string `locationName:"tagKeys" type:"list" required:"true"` +} + +// String returns the string representation +func (s UntagResourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UntagResourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UntagResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UntagResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.TagKeys == nil { + invalidParams.Add(request.NewErrParamRequired("TagKeys")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetResourceArn sets the ResourceArn field's value. +func (s *UntagResourceInput) SetResourceArn(v string) *UntagResourceInput { + s.ResourceArn = &v + return s +} + +// SetTagKeys sets the TagKeys field's value. +func (s *UntagResourceInput) SetTagKeys(v []*string) *UntagResourceInput { + s.TagKeys = v + return s +} + +type UntagResourceOutput struct { + _ struct{} `type:"structure"` +} + +// String returns the string representation +func (s UntagResourceOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation +func (s UntagResourceOutput) GoString() string { + return s.String() +} + type UploadLayerPartInput struct { _ struct{} `type:"structure"` @@ -5292,4 +5828,7 @@ const ( // TagStatusUntagged is a TagStatus enum value TagStatusUntagged = "UNTAGGED" + + // TagStatusAny is a TagStatus enum value + TagStatusAny = "ANY" ) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/ecriface/interface.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/ecriface/interface.go index d933cbf7..8c6bbb71 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/ecriface/interface.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/ecriface/interface.go @@ -137,6 +137,10 @@ type ECRAPI interface { ListImagesPages(*ecr.ListImagesInput, func(*ecr.ListImagesOutput, bool) bool) error ListImagesPagesWithContext(aws.Context, *ecr.ListImagesInput, func(*ecr.ListImagesOutput, bool) bool, ...request.Option) error + ListTagsForResource(*ecr.ListTagsForResourceInput) (*ecr.ListTagsForResourceOutput, error) + ListTagsForResourceWithContext(aws.Context, *ecr.ListTagsForResourceInput, ...request.Option) (*ecr.ListTagsForResourceOutput, error) + ListTagsForResourceRequest(*ecr.ListTagsForResourceInput) (*request.Request, *ecr.ListTagsForResourceOutput) + PutImage(*ecr.PutImageInput) (*ecr.PutImageOutput, error) PutImageWithContext(aws.Context, *ecr.PutImageInput, ...request.Option) (*ecr.PutImageOutput, error) PutImageRequest(*ecr.PutImageInput) (*request.Request, *ecr.PutImageOutput) @@ -153,6 +157,14 @@ type ECRAPI interface { StartLifecyclePolicyPreviewWithContext(aws.Context, *ecr.StartLifecyclePolicyPreviewInput, ...request.Option) (*ecr.StartLifecyclePolicyPreviewOutput, error) StartLifecyclePolicyPreviewRequest(*ecr.StartLifecyclePolicyPreviewInput) (*request.Request, *ecr.StartLifecyclePolicyPreviewOutput) + TagResource(*ecr.TagResourceInput) (*ecr.TagResourceOutput, error) + TagResourceWithContext(aws.Context, *ecr.TagResourceInput, ...request.Option) (*ecr.TagResourceOutput, error) + TagResourceRequest(*ecr.TagResourceInput) (*request.Request, *ecr.TagResourceOutput) + + UntagResource(*ecr.UntagResourceInput) (*ecr.UntagResourceOutput, error) + UntagResourceWithContext(aws.Context, *ecr.UntagResourceInput, ...request.Option) (*ecr.UntagResourceOutput, error) + UntagResourceRequest(*ecr.UntagResourceInput) (*request.Request, *ecr.UntagResourceOutput) + UploadLayerPart(*ecr.UploadLayerPartInput) (*ecr.UploadLayerPartOutput, error) UploadLayerPartWithContext(aws.Context, *ecr.UploadLayerPartInput, ...request.Option) (*ecr.UploadLayerPartOutput, error) UploadLayerPartRequest(*ecr.UploadLayerPartInput) (*request.Request, *ecr.UploadLayerPartOutput) diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go index 09e0595d..83490510 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/errors.go @@ -44,6 +44,14 @@ const ( // API request. ErrCodeInvalidParameterException = "InvalidParameterException" + // ErrCodeInvalidTagParameterException for service response error code + // "InvalidTagParameterException". + // + // An invalid parameter has been specified. Tag keys can have a maximum character + // length of 128 characters, and tag values can have a maximum length of 256 + // characters. + ErrCodeInvalidTagParameterException = "InvalidTagParameterException" + // ErrCodeLayerAlreadyExistsException for service response error code // "LayerAlreadyExistsException". // @@ -131,6 +139,13 @@ const ( // These errors are usually caused by a server-side issue. ErrCodeServerException = "ServerException" + // ErrCodeTooManyTagsException for service response error code + // "TooManyTagsException". + // + // The list of tags on the repository is over the limit. The maximum number + // of tags that can be applied to a repository is 50. + ErrCodeTooManyTagsException = "TooManyTagsException" + // ErrCodeUploadNotFoundException for service response error code // "UploadNotFoundException". // diff --git a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go index 7bdf2137..3eba7f69 100644 --- a/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go +++ b/ecr-login/vendor/github.com/aws/aws-sdk-go/service/ecr/service.go @@ -29,9 +29,9 @@ var initRequest func(*request.Request) // Service information constants const ( - ServiceName = "ecr" // Name of service. - EndpointsID = ServiceName // ID to lookup a service endpoint with. - ServiceID = "ECR" // ServiceID is a unique identifer of a specific service. + ServiceName = "ecr" // Name of service. + EndpointsID = "api.ecr" // ID to lookup a service endpoint with. + ServiceID = "ECR" // ServiceID is a unique identifer of a specific service. ) // New creates a new instance of the ECR client with a session. @@ -46,6 +46,9 @@ const ( // svc := ecr.New(mySession, aws.NewConfig().WithRegion("us-west-2")) func New(p client.ConfigProvider, cfgs ...*aws.Config) *ECR { c := p.ClientConfig(EndpointsID, cfgs...) + if c.SigningNameDerived || len(c.SigningName) == 0 { + c.SigningName = "ecr" + } return newClient(*c.Config, c.Handlers, c.Endpoint, c.SigningRegion, c.SigningName) } diff --git a/ecr-login/vendor/github.com/jmespath/go-jmespath/.gitignore b/ecr-login/vendor/github.com/jmespath/go-jmespath/.gitignore index 531fcc11..5091fb07 100644 --- a/ecr-login/vendor/github.com/jmespath/go-jmespath/.gitignore +++ b/ecr-login/vendor/github.com/jmespath/go-jmespath/.gitignore @@ -1,4 +1,4 @@ -jpgo +/jpgo jmespath-fuzz.zip cpu.out go-jmespath.test diff --git a/ecr-login/vendor/github.com/jmespath/go-jmespath/api.go b/ecr-login/vendor/github.com/jmespath/go-jmespath/api.go index 9cfa988b..8e26ffee 100644 --- a/ecr-login/vendor/github.com/jmespath/go-jmespath/api.go +++ b/ecr-login/vendor/github.com/jmespath/go-jmespath/api.go @@ -2,7 +2,7 @@ package jmespath import "strconv" -// JmesPath is the epresentation of a compiled JMES path query. A JmesPath is +// JMESPath is the epresentation of a compiled JMES path query. A JMESPath is // safe for concurrent use by multiple goroutines. type JMESPath struct { ast ASTNode