Skip to content

Instantly share code, notes, and snippets.

View mayankshah1607's full-sized avatar
πŸ•
Focusing

Mayank Shah mayankshah1607

πŸ•
Focusing
View GitHub Profile
apiVersion: apps/v1
kind: Deployment
metadata:
name: web
namespace: emojivoto
spec:
replicas: 1
selector:
matchLabels:
app: web-svc
absPath, err = filepath.Abs(destDir); err != nil {
feedback.Errorf("Cannot find absolute path: %v", err)
os.Exit(errorcodes.ErrGeneric)
}
configFileAbsPath := filepath.Join(absPath, defaultFileName)
msg := fmt.Sprintf("Config file written to: %s", configFileAbsPath)
# Install docker
sudo apt-get update && \
sudo apt-get install docker.io -y
# Install kubectl
curl -LO https://storage.googleapis.com/kubernetes-release/release/`curl -s https://storage.googleapis.com/kubernetes-release/release/stable.txt`/bin/linux/amd64/kubectl
chmod +x ./kubectl
sudo mv ./kubectl /usr/local/bin/kubectl
alias k=kubectl
@mayankshah1607
mayankshah1607 / CONTRIBUTING.md
Last active July 7, 2020 08:30
This gist is a sample of CONTRIBUTING.md for Enigma 6 code repo.

Contributing Guidelines

This doc defines a set of rules and protocols that must be strictly followed while contributing to this repository.

1. Commit messages

  • Use the -m flag only for minor changes. The message following the -m flag must be of the below format :

    <Verb in present tense> <Action>

    βœ… Examples of valid messages:

  • Added routes/routes.js file

from azure.cognitiveservices.search.imagesearch import ImageSearchAPI
from msrest.authentication import CognitiveServicesCredentials
subscription_key = "373c554ae1404f7dbbcb80b722b214c8"
def FetchImage(search_term):
client = ImageSearchAPI(CognitiveServicesCredentials(subscription_key))
image_results = client.images.search(query=search_term)