threetreeslight's blog
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
.circleci
blog
fluentd-gcp
grafana
kubernates
nginx
prometheus
scripts
.dockerignore
.gitignore
.gitmodules
Dockerfile
README.md
docker-compose.yml

README.md

Blog

CircleCI

Getting started on local

# To work enable assets link via docker
export DOCKER_HOST_IP=$(echo $DOCKER_HOST | sed 's/tcp:\/\///g' | sed 's/:.*//g')

$ docker-compose build
$ docker-compose up blog

local develoment utilities

send alert message

./scripts/send_alert.sh

GKE

preparation

attach cluster-admin role to me

kubectl create clusterrolebinding cluster-admin-binding \
--clusterrole cluster-admin \
--user $(gcloud config get-value account)

stop logging for custermize

gcloud beta container clusters update --logging-service=none blog-cluster

Environment

  • GF_SECURITY_ADMIN_PASSWOR
  • SLACK_WEBHOOK_URL

monitor

update

./scripts/restart_monitor.sh

connect

# prometheus
kubectl port-forward $(kubectl get pod --selector="app=monitor" -o jsonpath='{.items[0].metadata.name}') 9090:9090
# alertmanager
kubectl port-forward $(kubectl get pod --selector="app=monitor" -o jsonpath='{.items[0].metadata.name}') 9093:9093
logs
kubectl logs -f deployment/monitor blackbox-exporter
kubectl logs -f deployment/monitor alertmaanger
kubectl logs -f deployment/monitor prometheus
kubectl logs -f deployment/monitor grafana