This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xcode-select --install | |
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
brew doctor | |
brew install caskroom/cask/brew-cask |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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>] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#####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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Install Chef DK 0.18.30 | |
curl https://omnitruck.chef.io/install.sh | sudo bash -s -- -P chefdk -c stable -v 0.18.30 | |
#Install Few software | |
yum install vim tree git -y | |
#Run Chef client in localmode | |
chef-client --local-mode webserver.rb | |
#Generate cookobooks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
How to reverse a list in Python? | |
1. reverse in-place | |
list.reverse() | |
2. list slicing trick | |
lst[::-1] | |
3. Reversed iterator | |
reversed(lst) | |
list(reversed(lst)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
echo -e "\n --- \n Configuring Metrics Components \n --- \n" | |
echo -e "\t Service Accounts" | |
echo -e "\t\t Create a metrics-deployer service account:" | |
oc login --username=<admin_user> --password=<passwd> --namespace=openshift-infra | |
oc create -f - <<API | |
apiVersion: v1 |
NewerOlder