Categories
gcp Kubernetes

Kubernetes: Install Grafana & Prometheus on GKE using Helm Bitnami

Install Grafana https://github.com/bitnami/charts/tree/master/bitnami/grafana Create namespace kubectl create ns monitoring Add repo helm repo add bitnami https://charts.bitnami.com/bitnami Update repo helm repo update View version helm search repo -l bitnami/grafana | head Create custom_values.yaml https://github.com/bitnami/charts/blob/master/bitnami/grafana/values.yaml I added an annotation because I wanted an internal IP for the Load Balancer. Feel free to remove that section. vi custom_values.yaml […]

Categories
docker

Push to Docker Hub using GitHub Actions

Knock-knock! Who’s there? Jenkins. Jenkins who? jk 🤣 Links https://docs.github.com/en/actions https://github.com/actions https://github.com/marketplace (think of it as an alternative to Jenkins plugins) https://docs.github.com/en/actions/reference/workflow-syntax-for-github-actions https://lab.github.com/githubtraining/github-actions:-publish-to-github-packages Create & clone repo Create a GitHub repository. Clone your repository and cd into it. git clone git@github.com:itsmetommy/github-actions.git && cd github-actions Create secrets Settings → Secrets Click New repository secret. Create two secrets. Create DOCKER_USERNAME. […]

Categories
docker

Docker: PostgreSQL

https://hub.docker.com/_/postgres Download docker pull postgres Create Option 1 – docker run docker run -d \ –name postgres-itsmetommy \ -e POSTGRES_PASSWORD=12345 \ -p 5432:5432 \ postgres Option 2 – docker-compose cat <<EOF > docker-compose.yml version: ‘3’services: postgres: image: postgres environment: POSTGRES_PASSWORD: “12345” ports: – “5432:5432” container_name: postgres-itsmetommy EOF Create. docker-compose up -d Logs. docker-compose logs -f […]

Categories
gcp Kubernetes

Install Halyard & Spinnaker on GKE

Create IAM Service Account https://www.spinnaker.io/setup/quickstart/halyard-gke-deploy-rbac/#part-2-add-service-account-to-gcp Spinnaker will use this IAM Service Account to access Google Cloud Storage (GCS) (storage.admin). export SERVICE_ACCOUNT_NAME=spinnaker-itsmetommy-saexport SERVICE_ACCOUNT_FILE=spinnaker-itsmetommy-sa.json export SERVICE_ACCOUNT_DISPLAY_NAME=”Spinnaker Account”export PROJECT=$(gcloud info –format=’value(config.project)’)gcloud –project ${PROJECT} iam service-accounts create \ ${SERVICE_ACCOUNT_NAME} \ –display-name ${SERVICE_ACCOUNT_DISPLAY_NAME} sleep 10 SA_EMAIL=$(gcloud iam service-accounts list \ –project=${PROJECT} \ –filter=”email ~ ${SERVICE_ACCOUNT_NAME}” \ –format=’value(email)’)gcloud –project ${PROJECT} projects […]

Categories
AWS

Using multi-factor authentication (MFA) in AWS

https://aws.amazon.com/premiumsupport/knowledge-center/authenticate-mfa-cli/ I will go over setting up multiple AWS profiles using MFA. Create your Access key. Add account(s) This will update ~/.aws/credentials. It will create 3 profiles. aws configure –profile account1-default aws configure –profile account2-default aws configure –profile account3-default Example aws configure –profile account1-default AWS Access Key ID [None]: XXXXX # Updates ~/.aws/credentials AWS Secret Access Key [None]: […]