Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions cmd/awscliauth.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@ import (
"fmt"
"os"
"path"
"runtime"

"github.com/DevLabFoundry/aws-cli-auth/internal/credentialexchange"
"github.com/Ensono/eirctl/selfupdate"
"github.com/spf13/cobra"
)

Expand Down Expand Up @@ -68,10 +70,19 @@ NB: This cannot be higher than the 3600 as the API does not allow for AssumeRole
//
// IF you are making your sub commands public, you can just pass them directly `WithSubCommands`
func SubCommands() []func(*Root) {
suffix := fmt.Sprintf("aws-cli-auth-%s", runtime.GOOS)
if runtime.GOOS == "windows" {
suffix = suffix + "-" + runtime.GOARCH
}

uc := selfupdate.New("aws-cli-auth", "https://github.com/DevLabFoundry/aws-cli-auth/releases", selfupdate.WithDownloadSuffix(suffix))
return []func(*Root){
newSamlCmd,
newClearCmd,
newSpecificIdentityCmd,
func(rootCmd *Root) {
uc.AddToRootCommand(rootCmd.Cmd)
},
}
}

Expand Down
2 changes: 1 addition & 1 deletion eirctl.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ tasks:
- |
mkdir -p .deps
ldflags="-s -w -X \"github.com/{{.RepoOwner}}/{{.BinName}}/cmd.Version={{.Version}}\" -X \"github.com/{{.RepoOwner}}/{{.BinName}}/cmd.Revision={{.Revision}}\" -extldflags -static"
CGO_ENABLED=0 GOPATH=$PWD/.deps GOOS=${BUILD_GOOS} GOARCH=${BUILD_GOARCH} go build -mod=readonly -buildvcs=false -ldflags="$ldflags" -o dist/{{.BinName}}-${BUILD_GOOS}-${BUILD_GOARCH} .
CGO_ENABLED=0 GOPATH=$PWD/.deps GOOS=${BUILD_GOOS} GOARCH=${BUILD_GOARCH} go build -mod=readonly -buildvcs=false -ldflags="$ldflags" -o dist/{{.BinName}}-${BUILD_GOOS}-${BUILD_GOARCH}.exe .
variations:
- BUILD_GOOS: windows
BUILD_GOARCH: amd64
Expand Down
52 changes: 30 additions & 22 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,46 +1,54 @@
module github.com/DevLabFoundry/aws-cli-auth

go 1.25.1
go 1.25.4

require (
github.com/aws/aws-sdk-go-v2 v1.38.1
github.com/aws/aws-sdk-go-v2/config v1.31.2
github.com/aws/aws-sdk-go-v2/service/sts v1.38.0
github.com/aws/smithy-go v1.22.5
github.com/aws/aws-sdk-go-v2 v1.39.6
github.com/aws/aws-sdk-go-v2/config v1.31.20
github.com/aws/aws-sdk-go-v2/service/sts v1.40.2
github.com/aws/smithy-go v1.23.2
github.com/go-rod/rod v0.116.2
github.com/spf13/cobra v1.9.1
github.com/spf13/cobra v1.10.1
github.com/werf/lockgate v0.1.1
github.com/zalando/go-keyring v0.2.6
gopkg.in/ini.v1 v1.67.0
)

require (
github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db // indirect
github.com/rivo/uniseg v0.4.7 // indirect
github.com/schollz/progressbar/v3 v3.18.0 // indirect
golang.org/x/term v0.37.0 // indirect
)

require (
al.essio.dev/pkg/shellescape v1.6.0 // indirect
dario.cat/mergo v1.0.2
github.com/aws/aws-sdk-go-v2/credentials v1.18.6 // indirect
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.4 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.4 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.4 // indirect
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.3 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.0 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.4 // indirect
github.com/aws/aws-sdk-go-v2/service/sso v1.28.2 // indirect
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.33.2 // indirect
github.com/danieljoos/wincred v1.2.2 // indirect
github.com/Ensono/eirctl v0.9.6
github.com/aws/aws-sdk-go-v2/credentials v1.18.24 // indirect
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.18.13 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.4.13 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.7.13 // indirect
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.4 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.13.3 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.13.13 // indirect
github.com/aws/aws-sdk-go-v2/service/sso v1.30.3 // indirect
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.35.7 // indirect
github.com/danieljoos/wincred v1.2.3 // indirect
github.com/go-test/deep v1.1.1
github.com/godbus/dbus/v5 v5.1.0 // indirect
github.com/gofrs/flock v0.12.1 // indirect
github.com/gofrs/flock v0.13.0 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/inconshreveable/mousetrap v1.1.0 // indirect
github.com/spaolacci/murmur3 v1.1.0 // indirect
github.com/spf13/pflag v1.0.7 // indirect
github.com/ysmood/fetchup v0.5.2 // indirect
github.com/spf13/pflag v1.0.10 // indirect
github.com/ysmood/fetchup v0.5.3 // indirect
github.com/ysmood/goob v0.4.0 // indirect
github.com/ysmood/got v0.41.0 // indirect
github.com/ysmood/got v0.42.0 // indirect
github.com/ysmood/gson v0.7.3 // indirect
github.com/ysmood/leakless v0.9.0 // indirect
golang.org/x/crypto v0.41.0 // indirect
golang.org/x/sys v0.35.0 // indirect
golang.org/x/crypto v0.44.0 // indirect
golang.org/x/sys v0.38.0 // indirect
)

replace github.com/ysmood/fetchup => github.com/ysmood/fetchup v0.3.0
Loading
Loading