Creating Virtual environment in python
Lets say i want to create python virtual environment using python3 Make sure you have already installed python3 you may need to install pip & virtualenv if you dont have it before sudo easy_install pip sudo easy_install virtualenv #################################### mkdir practise3.8.2 && cd practise3.8.2 python3 -m venv ~/practise3.8.2/main (or) python3 -m venv version-3.8.2 ls -l … Continue reading Creating Virtual environment in python
Argo CD
Argo CD is a declarative, GitOps continuous delivery tool for Kubernetes. Deploying argo-cd https://argoproj.github.io/argo-cd/getting_started/ Argo components Lets deploy Argo-Cd in my kubernetes clusters check the latest tag : https://github.com/argoproj/argo-cd Ex: https://github.com/argoproj/argo-cd/releases/tag/v2.0.1 I have my local minikube setup already done. | ❭ minikube start 😄 minikube v1.20.0 on Darwin 10.15.4🐳 Preparing Kubernetes v1.20.2 on Docker … Continue reading Argo CD
Helm charts
Its package manager for Kubernetes , similar you yum, apt, homebrew, dnl example installing dynatrace https://docs.dynatrace.com/docs/ingest-from/setup-on-k8s/deployment/platform-observability#helm helm install dynatrace-operator oci://public.ecr.aws/dynatrace/dynatrace-operator \ --set "csidriver.enabled=false" \ --create-namespace \ --namespace dynatrace \ --atomic
postgres 11 master slave replication in ubuntu14.04
Install Postgres add-apt-repository 'deb http://apt.postgresql.org/pub/repos/apt/ trusty-pgdg main'wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -apt-get updateapt-get install postgresql-11 MASTER: 192.168.33.50SLAVE1: 192.168.33.51SLAVE2: 192.168.33.52 On master postgres@master:~$ su - postgres Note: Set password less auth b/w master & salve, master & slave2 vice-versa postgres@master:~$ service postgresql status11/main (port 5432): online postgres@master:~$ ssh-keygenGenerating public/private rsa key pair.Enter … Continue reading postgres 11 master slave replication in ubuntu14.04
Go Basics
Visit https://golang.org/doc/install for details on how to install w.r.t OS flavours In my case i am using linux OS [root@gomachine ~]# wget https://dl.google.com/go/go1.13.4.linux-amd64.tar.gz [root@gomachine ~]# ls -l total 117244 -rw-r--r--. 1 root root 120054682 Nov 1 00:19 go1.13.4.linux-amd64.tar.gz [root@gomachine ~]# tar -C /usr/local -xzf go1.13.4.linux-amd64.tar.gz [root@gomachine ~]# ls -l /usr/local/go/ total 204 drwxr-xr-x. 2 root … Continue reading Go Basics
POM file
A Project Object Model or POM is the fundamental unit of work in Maven. It is an XML file that contains information about the project and configuration details used by Maven to build the project. Minimal POM The minimum requirement for a POM are the following: project root modelVersion - should be set to 4.0.0 … Continue reading POM file
Install openshift 4 on aws
Before proceeding make sure you have a domain in aws(route 53) If you don't have visit https://console.aws.amazon.com/route53/ and get it. For now i have purchased redhatocp.com [root@localhost tmp]# yum install awscli Note: Create IAM role with admin access [root@localhost tmp]# aws configure AWS Access Key ID [None]: AWS Secret Access Key [None]: Default region name … Continue reading Install openshift 4 on aws
Lambda function in python
Few key points about lambda function 1)Not defined by def keyword 2)Return expression not value 3)One-line function 4)Any number of arguments 5)Defined by using lambda keyword 6)Functions does not have any name 7)Can not access global variable syntax: lambda arguments:expression Ex: sum = (lambda x,y: x+y) print("addition of x and y is",sum(4,6)) o/p: addition of … Continue reading Lambda function in python
Global and local variables in python
Its all about the scope of a variable variable defined at the top of all functions will have global scope. variables defined in function are called local variables & the life of that variable is with in the function only . #### Global variable a = 10 #### funtion defination def display(): b=20 print("the value … Continue reading Global and local variables in python
