Skip to content

Instantly share code, notes, and snippets.

View rgodishela's full-sized avatar

Ramesh Godishela rgodishela

  • https://github.com/salesforce
  • Hyderabad, India
View GitHub Profile
@rgodishela
rgodishela / AWS Dynamic Inventory using Ansible
Created April 23, 2017 16:06
AWS Dynamic inventory creation using Ansible.
AWS Dynamic inventory creation using Ansible.
— Download Boto
sudo pip install boto
— Find the Access ID and Security Key from your aws account.
— Get the Access ID, and Security Key
— Make sure that right Policy’s are assigned
@rgodishela
rgodishela / doctl
Created April 23, 2017 16:19
Digital Ocean Command Line Interface
DOCTL
Installation
Option 1 – Download a Release from GitHub
Visit the Releases page for the doctl GitHub project.
https://github.com/digitalocean/doctl/releases
tar xf ~/doctl-1.4.0-linux-amd64.tar.gz
sudo mv ~/doctl /usr/local/bin
Configure
@rgodishela
rgodishela / mac_setup.txt
Created July 25, 2018 07:36
MacbookSetup
xcode-select --install
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew doctor
brew install caskroom/cask/brew-cask
@rgodishela
rgodishela / liveness.txt
Created June 26, 2018 16:34
Liveness check
#Install Google cloud SDK
curl https://sdk.cloud.google.com | bash
exec -l $SHELL
# Setup the GCP to work with gcloud, enable required API's
gcloud init
gcloud config set project PROJECT_ID
gcloud config set compute/zone COMPUTE_ZONE
@rgodishela
rgodishela / kubernetes-ubuntu-install.sh
Created April 11, 2018 10:10 — forked from sanketsudake/kubernetes-ubuntu-install.sh
[Ubuntu Linux]Kubernetes Minikube Helm Installation
# Install virtualbox
sudo apt install virtualbox
# Install Kubectl
curl -LO https://storage.googleapis.com/kubernetes-release/release/$(curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt)/bin/darwin/amd64/kubectl && chmod +x kubectl && sudo mv kubectl /usr/local/bin
# Install Minikube
curl -Lo minikube https://storage.googleapis.com/minikube/releases/v0.14.0/minikube-darwin-amd64 && chmod +x minikube && sudo mv minikube /usr/local/bin/
# Launch Minikube
minikube start
@rgodishela
rgodishela / dcos marathon
Last active March 25, 2018 18:41
dcos marathon cli
dcos package --config-schema
dcos package --help
dcos package --info
dcos package describe <package-name>
[(--app [--render]) --cli --config --options=<file>]
[--package-version=<package-version>]
dcos package describe <package-name> --package-versions
dcos package install <package-name>
[(--cli [--global]) | --app]
[--package-version=<package-version>]
@rgodishela
rgodishela / powershell_on_macosx
Last active December 24, 2017 08:11
Powershell on MacOSX
#Install Powershell
bash <(curl -fsSL https://raw.githubusercontent.com/PowerShell/PowerShell/v6.0.0-beta.1/tools/download.sh)
#Uninstall all versions of powershell
Uninstall-Package -Name AWSPowerShell.NetCore -AllVersions
#Install Powershell
Install-Package -Name AWSPowerShell.NetCore -Source https://www.powershellgallery.com/api/v2/ -ProviderName NuGet -ExcludeVersion -Destination $PSHOME/Modules -Scope CurrentUser
@rgodishela
rgodishela / dynamodb_autoscale.ps1
Last active October 14, 2017 16:34
powershell script to Autoscale dynamodb table
#####IMPORTANT INSTRUCTIONS to execute these instrcutions
#1. U should have role and policy created and attach them to each other
#2. U should have dynamodb table
#3. u should have AWS Tools for powershell 3.3.169
#First Get the Role Arn
$DDBRole = Get-IAMRole -RoleName ddb-role
$DDBRoleArn = $DDBRole.Arn
#Get the Table Name
@rgodishela
rgodishela / pp_json
Created September 15, 2017 09:28
pp_json
import json
def pp_json(json_thing, sort=True, indents=4):
if type(json_thing) is str:
print(json.dumps(json.loads(json_thing), sort_keys=sort, indent=indents))
else:
print(json.dumps(json_thing, sort_keys=sort, indent=indents))
return None
pp_json(your_json_string_or_dict)
@rgodishela
rgodishela / prometheus
Created July 30, 2017 17:13
prometheus info
Videos:
https://prometheus.io/docs/introduction/media/
https://github.com/prometheus/alertmanager
https://prometheus.io/docs/alerting/alertmanager/
https://prometheus.io/docs/alerting/notification_examples/
https://github.com/prometheus/alertmanager/blob/master/doc/examples/simple.yml
https://quay.io/repository/prometheus/alertmanager
https://prometheus.io/webtools/alerting/routing-tree-editor/
https://www.youtube.com/watch?v=cR9Fp6hwTLE&list=PLqm7NmbgjUExeDZU8xb2nxz-ysnjuC2Mz&index=4