Compare commits

...

3 Commits

Author SHA1 Message Date
586538f14f Catch errors rather than exit early
Signed-off-by: Marcus Noble <github@marcusnoble.co.uk>
2021-12-13 15:11:38 +00:00
56e07cfd24 Set kubeconfig file on login
Signed-off-by: Marcus Noble <github@marcusnoble.co.uk>
2021-12-13 15:11:17 +00:00
f79c757168 Install yq
Signed-off-by: Marcus Noble <github@marcusnoble.co.uk>
2021-12-13 15:11:01 +00:00
3 changed files with 4 additions and 6 deletions

View File

@@ -1,7 +1,5 @@
#!/usr/bin/env bash
set -e
NAMESPACE="org-giantswarm"
RELEASE="20.0.0-alpha1"
PROVIDER="aws"

View File

@@ -56,13 +56,13 @@ done
case ${#POS_ARGS[@]} in
1)
kubectl gs login ${POS_ARGS[0]} ${DEBUG} 2>/dev/null || opsctl kgs login -i ${POS_ARGS[0]} || opsctl create kubeconfig ${POS_ARGS[0]}
kubectl gs login --kubeconfig=${KUBECONFIG} ${POS_ARGS[0]} ${DEBUG} 2>/dev/null || opsctl kgs login -i ${POS_ARGS[0]} || opsctl create kubeconfig ${POS_ARGS[0]}
;;
2)
kubectl gs login ${POS_ARGS[0]} --workload-cluster ${POS_ARGS[1]} --certificate-group ${CERTIFICATE_GROUP} --certificate-ttl ${TTL} ${DEBUG}
kubectl gs login --kubeconfig=${KUBECONFIG} ${POS_ARGS[0]} --workload-cluster ${POS_ARGS[1]} --certificate-group ${CERTIFICATE_GROUP} --certificate-ttl ${TTL} ${DEBUG}
;;
3)
kubectl gs login ${POS_ARGS[0]} --workload-cluster ${POS_ARGS[1]} --certificate-group ${CERTIFICATE_GROUP} --certificate-ttl ${TTL} --organization ${POS_ARGS[2]} ${DEBUG}
kubectl gs login --kubeconfig=${KUBECONFIG} ${POS_ARGS[0]} --workload-cluster ${POS_ARGS[1]} --certificate-group ${CERTIFICATE_GROUP} --certificate-ttl ${TTL} --organization ${POS_ARGS[2]} ${DEBUG}
;;
*)
print_usage

View File

@@ -28,7 +28,7 @@ BREW_TOOLS=(
argocd bandwhich bat danielfoehrkn/switch/switch derailed/k9s/k9s dive dog duf dust exa fd fzf
git-delta git-delta go helm homebrew/cask-fonts/font-open-dyslexic-nerd-font htop jq kind krew
kubectl kubectx kustomize node procs progress ripgrep rs/tap/curlie rust starship
tektoncd/tools/tektoncd-cli tldr tailscale
tektoncd/tools/tektoncd-cli tldr tailscale python-yq
)
CARGO_TOOLS=( macchina bottom )
NODE_TOOLS=( git-split-diffs )