add in scripts

This commit is contained in:
Seth Call 2025-07-20 17:17:36 -05:00
parent f7119c091b
commit fb5c0c7775
11 changed files with 22 additions and 0 deletions

2
scripts/dev-setup Normal file
View File

@ -0,0 +1,2 @@
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx

1
scripts/get-argocd Executable file
View File

@ -0,0 +1 @@
kubectl get ingress -n argocd

4
scripts/get-argocd-host Executable file
View File

@ -0,0 +1,4 @@
#!/bin/bash
ARGO_INGRESS_NAME="argocd-server-ingress" # Or whatever your Argo CD ingress is named
ARGO_NAMESPACE="argocd" # Your Argo CD namespace
kubectl get ingress "$ARGO_INGRESS_NAME" -n "$ARGO_NAMESPACE" -o jsonpath='{.spec.rules[0].host}' 2>/dev/null

1
scripts/get-argocd-secret Executable file
View File

@ -0,0 +1 @@
kubectl -n argocd get secret argocd-initial-admin-secret -o jsonpath="{.data.password}" | base64 -d; echo

2
scripts/get-monitoring-ingress Executable file
View File

@ -0,0 +1,2 @@
kubectl get ingress -n monitoring monitoring-kube-prometheus-alertmanager -o yaml
kubectl get ingress -n monitoring monitoring-kube-prometheus-prometheus -o yaml

View File

@ -0,0 +1,2 @@
# run in k8s/monitoring folder
helm upgrade monitoring . --namespace monitoring -f values-production.yaml

1
scripts/list-all-monitoring Executable file
View File

@ -0,0 +1 @@
kubectl get all -n monitoring #--showlabels

1
scripts/list-namespaces Executable file
View File

@ -0,0 +1 @@
kubectl get pods --all-namespaces

1
scripts/list-pods-monitoring Executable file
View File

@ -0,0 +1 @@
kubectl get pods -n monitoring

6
scripts/login-argocd Executable file
View File

@ -0,0 +1,6 @@
#!/bin/bash
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
PASS=$($SCRIPT_DIR/get-argocd-secret)
ARGOCD_HOST=$($SCRIPT_DIR/get-argocd-host)
echo $PASS $ARGOCD_HOST
argocd login $ARGOCD_HOST --username admin --password $PASS --insecure # Add --insecure if you're using a self-signed cert or port-forwarding

1
scripts/logs-prom-watch Executable file
View File

@ -0,0 +1 @@
kubectl logs -f prometheus-monitoring-kube-prometheus-prometheus-0 -n monitoring