From 14ee94d297a8e7485fbfe555d53c557f63f059ad Mon Sep 17 00:00:00 2001 From: Allison Doami Date: Wed, 18 Dec 2024 11:28:58 -0800 Subject: [PATCH 1/4] fix: v2 go.mod --- oidc_cli/go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/oidc_cli/go.mod b/oidc_cli/go.mod index 2d65bd72..b397546f 100644 --- a/oidc_cli/go.mod +++ b/oidc_cli/go.mod @@ -1,4 +1,4 @@ -module github.com/chanzuckerberg/go-misc/oidc_cli +module github.com/chanzuckerberg/go-misc/oidc_cli/v2 go 1.21 From 36c94774535ea97f027945143cc6050af404b36e Mon Sep 17 00:00:00 2001 From: alldoami Date: Wed, 18 Dec 2024 19:29:45 +0000 Subject: [PATCH 2/4] ci - update oidc_cli/go.mod --- oidc_cli/go.mod | 2 +- oidc_cli/go.sum | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/oidc_cli/go.mod b/oidc_cli/go.mod index b397546f..23571a37 100644 --- a/oidc_cli/go.mod +++ b/oidc_cli/go.mod @@ -6,6 +6,7 @@ toolchain go1.21.1 require ( github.com/aws/aws-sdk-go v1.51.4 + github.com/chanzuckerberg/go-misc/oidc_cli v0.0.0-20241218181938-e245ce8d3ba5 github.com/chanzuckerberg/go-misc/osutil v0.0.0-20240404182313-43e397411f6e github.com/chanzuckerberg/go-misc/pidlock v0.0.0-20240320212149-709d6d5c338b github.com/coreos/go-oidc v2.2.1+incompatible @@ -30,7 +31,6 @@ require ( github.com/golang/protobuf v1.5.4 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect - github.com/kr/text v0.2.0 // indirect github.com/nightlyone/lockfile v1.0.0 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/pquerna/cachecontrol v0.2.0 // indirect diff --git a/oidc_cli/go.sum b/oidc_cli/go.sum index 6f9d753c..ec508962 100644 --- a/oidc_cli/go.sum +++ b/oidc_cli/go.sum @@ -2,9 +2,10 @@ github.com/aws/aws-sdk-go v1.51.4 h1:yOVfGhRJyReBrACK0alLosJl8iXhWkNY1vrePYmhHdw github.com/aws/aws-sdk-go v1.51.4/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= +github.com/chanzuckerberg/go-misc/oidc_cli v0.0.0-20241218181938-e245ce8d3ba5 h1:DjCNt2+LstHrZ24VW+99lRt0y6to0EQ+j7zhDThNrms= +github.com/chanzuckerberg/go-misc/oidc_cli v0.0.0-20241218181938-e245ce8d3ba5/go.mod h1:ogMmcHO1nKTzDGrdogtWS4StwZFLZ+COEyiEaxg++cw= github.com/coreos/go-oidc v2.2.1+incompatible h1:mh48q/BqXqgjVHpy2ZY7WnWAbenxRjsz9N1i1YxjHAk= github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= -github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/danieljoos/wincred v1.1.0/go.mod h1:XYlo+eRTsVA9aHGp7NGjFkPla4m+DCL7hqDjlFjiygg= github.com/danieljoos/wincred v1.2.1 h1:dl9cBrupW8+r5250DYkYxocLeZ1Y4vB1kxgtjxw8GQs= github.com/danieljoos/wincred v1.2.1/go.mod h1:uGaFL9fDn3OLTvzCGulzE+SzjEe5NGlh5FdCcyfPwps= From 009d62ae3a710fee67515012f41ddd61a27602f6 Mon Sep 17 00:00:00 2001 From: Allison Doami Date: Wed, 18 Dec 2024 11:37:35 -0800 Subject: [PATCH 3/4] update --- oidc_cli/aws_sts.go | 4 ++-- oidc_cli/go.sum | 4 ++-- oidc_cli/oidc_impl/cache/cache.go | 4 ++-- oidc_cli/oidc_impl/cache/cache_test.go | 4 ++-- oidc_cli/oidc_impl/storage/file.go | 2 +- oidc_cli/oidc_impl/storage/keyring.go | 2 +- oidc_cli/oidc_impl/storage/storage.go | 2 +- oidc_cli/oidc_impl/token_getter.go | 6 +++--- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/oidc_cli/aws_sts.go b/oidc_cli/aws_sts.go index 3fa2fdb6..6a8ec395 100644 --- a/oidc_cli/aws_sts.go +++ b/oidc_cli/aws_sts.go @@ -7,8 +7,8 @@ import ( "github.com/aws/aws-sdk-go/aws/credentials" "github.com/aws/aws-sdk-go/aws/credentials/stscreds" "github.com/aws/aws-sdk-go/service/sts/stsiface" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" ) type AwsOIDCCredsProviderConfig struct { diff --git a/oidc_cli/go.sum b/oidc_cli/go.sum index ec508962..ec7d928d 100644 --- a/oidc_cli/go.sum +++ b/oidc_cli/go.sum @@ -2,8 +2,8 @@ github.com/aws/aws-sdk-go v1.51.4 h1:yOVfGhRJyReBrACK0alLosJl8iXhWkNY1vrePYmhHdw github.com/aws/aws-sdk-go v1.51.4/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/chanzuckerberg/go-misc/oidc_cli v0.0.0-20241218181938-e245ce8d3ba5 h1:DjCNt2+LstHrZ24VW+99lRt0y6to0EQ+j7zhDThNrms= -github.com/chanzuckerberg/go-misc/oidc_cli v0.0.0-20241218181938-e245ce8d3ba5/go.mod h1:ogMmcHO1nKTzDGrdogtWS4StwZFLZ+COEyiEaxg++cw= +github.com/chanzuckerberg/go-misc/oidc_cli/v2 v0.0.0-20241218181938-e245ce8d3ba5 h1:DjCNt2+LstHrZ24VW+99lRt0y6to0EQ+j7zhDThNrms= +github.com/chanzuckerberg/go-misc/oidc_cli/v2 v0.0.0-20241218181938-e245ce8d3ba5/go.mod h1:ogMmcHO1nKTzDGrdogtWS4StwZFLZ+COEyiEaxg++cw= github.com/coreos/go-oidc v2.2.1+incompatible h1:mh48q/BqXqgjVHpy2ZY7WnWAbenxRjsz9N1i1YxjHAk= github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= github.com/danieljoos/wincred v1.1.0/go.mod h1:XYlo+eRTsVA9aHGp7NGjFkPla4m+DCL7hqDjlFjiygg= diff --git a/oidc_cli/oidc_impl/cache/cache.go b/oidc_cli/oidc_impl/cache/cache.go index 8451bb5b..0c314110 100644 --- a/oidc_cli/oidc_impl/cache/cache.go +++ b/oidc_cli/oidc_impl/cache/cache.go @@ -7,8 +7,8 @@ import ( "fmt" "io" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/storage" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/storage" "github.com/chanzuckerberg/go-misc/pidlock" "github.com/pkg/errors" "github.com/sirupsen/logrus" diff --git a/oidc_cli/oidc_impl/cache/cache_test.go b/oidc_cli/oidc_impl/cache/cache_test.go index 98e11fdf..ec1b6a40 100644 --- a/oidc_cli/oidc_impl/cache/cache_test.go +++ b/oidc_cli/oidc_impl/cache/cache_test.go @@ -8,8 +8,8 @@ import ( "testing" "time" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/storage" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/storage" "github.com/chanzuckerberg/go-misc/pidlock" "github.com/google/uuid" diff --git a/oidc_cli/oidc_impl/storage/file.go b/oidc_cli/oidc_impl/storage/file.go index 49a2112a..6695c205 100644 --- a/oidc_cli/oidc_impl/storage/file.go +++ b/oidc_cli/oidc_impl/storage/file.go @@ -10,7 +10,7 @@ import ( "path" "sync" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" "github.com/pkg/errors" ) diff --git a/oidc_cli/oidc_impl/storage/keyring.go b/oidc_cli/oidc_impl/storage/keyring.go index 3f46bbd6..29b6ba51 100644 --- a/oidc_cli/oidc_impl/storage/keyring.go +++ b/oidc_cli/oidc_impl/storage/keyring.go @@ -5,7 +5,7 @@ import ( "fmt" "sync" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" "github.com/pkg/errors" "github.com/zalando/go-keyring" ) diff --git a/oidc_cli/oidc_impl/storage/storage.go b/oidc_cli/oidc_impl/storage/storage.go index 4efaa89b..0e3b8c67 100644 --- a/oidc_cli/oidc_impl/storage/storage.go +++ b/oidc_cli/oidc_impl/storage/storage.go @@ -3,7 +3,7 @@ package storage import ( "context" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" "github.com/chanzuckerberg/go-misc/osutil" "github.com/mitchellh/go-homedir" "github.com/pkg/errors" diff --git a/oidc_cli/oidc_impl/token_getter.go b/oidc_cli/oidc_impl/token_getter.go index a6bda730..e1970889 100644 --- a/oidc_cli/oidc_impl/token_getter.go +++ b/oidc_cli/oidc_impl/token_getter.go @@ -4,9 +4,9 @@ import ( "context" "time" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/cache" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/client" - "github.com/chanzuckerberg/go-misc/oidc_cli/oidc_impl/storage" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/cache" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/client" + "github.com/chanzuckerberg/go-misc/oidc_cli/v2/oidc_impl/storage" "github.com/chanzuckerberg/go-misc/pidlock" "github.com/pkg/errors" ) From 7ee0bf545e27563645f27078818a12aeab6d71b6 Mon Sep 17 00:00:00 2001 From: alldoami Date: Wed, 18 Dec 2024 19:38:21 +0000 Subject: [PATCH 4/4] ci - update oidc_cli/go.mod --- oidc_cli/go.mod | 2 +- oidc_cli/go.sum | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/oidc_cli/go.mod b/oidc_cli/go.mod index 23571a37..b397546f 100644 --- a/oidc_cli/go.mod +++ b/oidc_cli/go.mod @@ -6,7 +6,6 @@ toolchain go1.21.1 require ( github.com/aws/aws-sdk-go v1.51.4 - github.com/chanzuckerberg/go-misc/oidc_cli v0.0.0-20241218181938-e245ce8d3ba5 github.com/chanzuckerberg/go-misc/osutil v0.0.0-20240404182313-43e397411f6e github.com/chanzuckerberg/go-misc/pidlock v0.0.0-20240320212149-709d6d5c338b github.com/coreos/go-oidc v2.2.1+incompatible @@ -31,6 +30,7 @@ require ( github.com/golang/protobuf v1.5.4 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect + github.com/kr/text v0.2.0 // indirect github.com/nightlyone/lockfile v1.0.0 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect github.com/pquerna/cachecontrol v0.2.0 // indirect diff --git a/oidc_cli/go.sum b/oidc_cli/go.sum index ec7d928d..6f9d753c 100644 --- a/oidc_cli/go.sum +++ b/oidc_cli/go.sum @@ -2,10 +2,9 @@ github.com/aws/aws-sdk-go v1.51.4 h1:yOVfGhRJyReBrACK0alLosJl8iXhWkNY1vrePYmhHdw github.com/aws/aws-sdk-go v1.51.4/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/chanzuckerberg/go-misc/oidc_cli/v2 v0.0.0-20241218181938-e245ce8d3ba5 h1:DjCNt2+LstHrZ24VW+99lRt0y6to0EQ+j7zhDThNrms= -github.com/chanzuckerberg/go-misc/oidc_cli/v2 v0.0.0-20241218181938-e245ce8d3ba5/go.mod h1:ogMmcHO1nKTzDGrdogtWS4StwZFLZ+COEyiEaxg++cw= github.com/coreos/go-oidc v2.2.1+incompatible h1:mh48q/BqXqgjVHpy2ZY7WnWAbenxRjsz9N1i1YxjHAk= github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc= +github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/danieljoos/wincred v1.1.0/go.mod h1:XYlo+eRTsVA9aHGp7NGjFkPla4m+DCL7hqDjlFjiygg= github.com/danieljoos/wincred v1.2.1 h1:dl9cBrupW8+r5250DYkYxocLeZ1Y4vB1kxgtjxw8GQs= github.com/danieljoos/wincred v1.2.1/go.mod h1:uGaFL9fDn3OLTvzCGulzE+SzjEe5NGlh5FdCcyfPwps=