Types of Arguments There are 4 types how we can pass arguments to functions in python 1) Default arguments 2) Required arguments 3) Keyword arguments 4) Variable number of arguments Default arguments: Default values indicate that the function argument will take that value if no argument value is passed during function call. The default value … Continue reading Types of arguments in python user-defined function
Identifiers and Operators in python
Identifiers Ex: a=10 b='xyz' Here a And b are identifiers. Identifiers can start with _ or a-z or A-Z & alphabet followed by number (0-9) but not with 0-9 # Starting of python programing ''' Multy line comment bla bla bla and that it ''' print("This is very begging") a=10 b='xyz' print(a,b) _a = 50 … Continue reading Identifiers and Operators in python
Pod Network
What is POD? A point of delivery, or PoD, is "a module of network, compute, storage, and application components that work together to deliver networking services. An overlay network is a computer network that is built on top of another network. An overlay is a virtual network that is built on top of underlying network infrastructure. The purpose is to implement … Continue reading Pod Network
Install kubernetes with kubeadm
Add repo to pull required packages in all nodes cat << /etc/yum.repos.d/kubernetes.repo [kubernetes] name=Kubernetes baseurl=https://packages.cloud.google.com/yum/repos/kubernetes-el7-x86_64 enabled=1 gpgcheck=1 repo_gpgcheck=1 gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg EOF yum install kubeadm kubelet kubectl -y Installed: kubeadm.x86_64 0:1.13.4-0 kubectl.x86_64 0:1.13.4-0 kubelet.x86_64 0:1.13.4-0 Dependency Installed: conntrack-tools.x86_64 0:1.4.4-4.el7 cri-tools.x86_64 0:1.12.0-0 kubernetes-cni.x86_64 0:0.6.0-0 libnetfilter_cthelper.x86_64 0:1.0.0-9.el7 libnetfilter_cttimeout.x86_64 0:1.0.0-6.el7 libnetfilter_queue.x86_64 0:1.0.2-2.el7_2 socat.x86_64 0:1.7.3.2-2.el7 swapoff -a yum install docker … Continue reading Install kubernetes with kubeadm
Installing and working with helm
Download required version of Helm wget https://storage.googleapis.com/kubernetes-helm/helm-v2.13.0-linux-amd64.tar.gz tar -zxvf helm-v2.13.0-linux-amd64.tar.gz mv linux-amd64/helm /usr/local/bin/helm [root@remoteuser ~]# helm The Kubernetes package manager To begin working with Helm, run the 'helm init' command: $ helm init This will install Tiller to your running Kubernetes cluster. It will also set up any necessary local configuration. Common actions from this … Continue reading Installing and working with helm
What Kubernetes can resolve
Replication of controllers Auto Scaling Load Balancing Rolling Update Logging Across components Monitoring Health Checks ServiceDiscovery Authentication....... Kubernetes Architecture Kube-Apiserver: The Kubernetes API server validates and configures data for the api objects which include pods, services, replicationcontrollers, and others. The API Server services REST operations and provides the frontend to the cluster’s … Continue reading What Kubernetes can resolve
create kubernetes cluster in gcp
Use google cloud shell for executing below commands gcloud components install kubectl gcloud container clusters create demo123 \ --num-nodes=3 \ --machine-type=n1-standard-2 \ --zone=us-central1-b ... kubeconfig entry generated for demo123. NAME LOCATION MASTER_VERSION MASTER_IP MACHINE_TYPE NODE_VERSION NUM_NODES STATUS demo123 us-central1-b 1.11.7-gke.4 35.226.229.88 n1-standard-2 1.11.7-gke.4 3 RUNNING kubectl get nodes NAME STATUS ROLES AGE VERSION gke-demo123-default-pool-e76d0a68-0hkc Ready <none> … Continue reading create kubernetes cluster in gcp
cloud functions in gcp
gcloud function is similar to serverless concept git clone https://github.com/GoogleCloudPlatform/nodejs-docs-samples.git Cloning into 'nodejs-docs-samples'... remote: Enumerating objects: 89, done. remote: Counting objects: 100% (89/89), done. remote: Compressing objects: 100% (87/87), done. remote: Total 13383 (delta 39), reused 2 (delta 0), pack-reused 13294 Receiving objects: 100% (13383/13383), 14.61 MiB | 2.31 MiB/s, done. Resolving deltas: 100% (8460/8460), … Continue reading cloud functions in gcp
mutability and immutability in python
Best way when dealing with python is use anaconda https://www.anaconda.com/distribution/ will see what is mutability and immutability , for that we wanted to what are available keywords in python, & which came under mutable & which comes and immutable . Standard data types Values can not be changed ==> Immutable Data Types ----> Number, String,Tuple … Continue reading mutability and immutability in python
Setting Up GitHub Enterprise in GCP
Few required url to explore https://github.com/enterprise https://enterprise.github.com/trial https://help.github.com/enterprise/2.16/ https://help.github.com/enterprise/2.16/admin/guides/installation/ https://help.github.com/enterprise/2.16/admin/guides/installation/installing-github-enterprise-server-on-google-cloud-platform/ If we are good at gcp cli utility , it make our work easier to browse things . root@cloudshell:~$ gcloud compute images list --project github-enterprise-public --no-standard-images NAME PROJECT … Continue reading Setting Up GitHub Enterprise in GCP
