Abhishek Pratap Singh https://procrypt.github.io/ Recent content on Abhishek Pratap Singh Hugo -- gohugo.io abhishek@linux.com (Abhishek Pratap Singh) abhishek@linux.com (Abhishek Pratap Singh) Thu, 15 Mar 2018 00:00:00 +0000 Hacker Rank 30 Days Challenge in Golang https://procrypt.github.io/post/2018-03-15-hacker-rank-30-days-challenge-solution-golang/ Thu, 15 Mar 2018 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2018-03-15-hacker-rank-30-days-challenge-solution-golang/ Day 0: Hello, World. Task To complete this challenge, you must save a line of input from stdin to a variable, print Hello, World. on a single line, and finally print the value of your variable on a second line. package main import ( "fmt" "bufio" "os" ) func main() { reader := bufio.NewReader(os.Stdin) inputString, _ := reader.ReadString('\n') fmt.Println("Hello, World.") fmt.Println(inputString) } Day 1: Data Type Task Declare 3 variables: one of type int, one of type double, and one of type String. My First Post https://procrypt.github.io/posts/my-first-post/ Wed, 21 Feb 2018 02:36:08 -0500 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/posts/my-first-post/ Sorting Structs in Golang https://procrypt.github.io/post/2017-06-01-sorting-structs-in-golang/ Thu, 01 Jun 2017 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2017-06-01-sorting-structs-in-golang/ We can not directly use the sorting library Sort for sorting structs in Golang. In order to sort a struct the underlying struct should implement a special interface called sort.Interface This interface requires three methods Len, Swap and Less Let’s try to understand this using an example. Define a struct type EnvVar struct { Name string value string } Here we have a struct struct named EnvVar with two fields Name and value Setting up Multinode OpenShift Cluster https://procrypt.github.io/post/2017-2-22-setting-up-multinode-openshift-cluster/ Wed, 22 Feb 2017 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2017-2-22-setting-up-multinode-openshift-cluster/ OpenShift is Red Hat’s PaaS (Platform-as-a-Service) that allow developers to quickly develop, host, and scale applications in cloud. Based on top of Docker containers and the Kubernetes container cluster manager, OpenShift adds developer and operational centric tools to enable rapid application development, easy deployment and scaling, and long-term lifecycle maintenance for small and large teams and applications. In this blog, we will be setting up a Multinode OpenShift Cluster (Single Master with two nodes) and will deploy a sample application on it. Installing Minikube https://procrypt.github.io/post/2016-12-16-installing-minikube/ Fri, 16 Dec 2016 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2016-12-16-installing-minikube/ Kubernetes is a container orchestration tool developed by Google, written completely in Golang. It provides a platform for deployment, scaling and automating your application in a containerized environment. Kubernetes helps you scale up your application with ease and make deployment quick. Containerize an application by creating Docker config files and build processes to produce all the necessary Docker images Configure and launch an auto-scaling, self-healing Kubernetes cluster. It is sometimes very difficult to set up a Kubernetes cluster bit thanks to minikube we can set it it up within few commands so that you can run a single node Kunbernetes cluster locally. Getting started with OpenShift https://procrypt.github.io/post/2016-12-08-getting-started-with-openshift/ Thu, 08 Dec 2016 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2016-12-08-getting-started-with-openshift/ OpenShift is Red Hat’s PaaS (Platform-as-a-Service) that allow developers to quickly develop, host, and scale applications in cloud. Based on top of Docker containers and the Kubernetes container cluster manager, OpenShift adds developer and operational centric tools to enable rapid application development, easy deployment and scaling, and long-term lifecycle maintenance for small and large teams and applications. There are a couple of ways by which you can setup your OpenShift cluster like minishift , oc cluster up. Getting started with Kompose https://procrypt.github.io/post/2016-11-02-getting-started-with-kompose/ Wed, 16 Nov 2016 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2016-11-02-getting-started-with-kompose/ kompose is a tool to help users, familiar with docker-compose, move to Kubernetes. It takes a Docker Compose file and translates it into Kubernetes resources. kompose is a convenience tool to go from local Docker development to managing your application with Kubernetes. We don’t assume that the transformation from docker compose format to Kubernetes API objects will be perfect, but it helps tremendously to start Kubernetizing your application. In this example we will create OpenShift artifacts for guestbook app from the docker-compose file using kompose. Getting started with Ansible Containers https://procrypt.github.io/post/2016-11-08-getting-started-with-ansible-container/ Tue, 08 Nov 2016 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/post/2016-11-08-getting-started-with-ansible-container/ Ansible Container is the ultimate workflow for container development, testing, and deployment. Ansible Container enables you to build Docker images and orchestrate containers using only Ansible playbooks. Describe your application in a Docker Compose-like format and, rather than using a Dockerfile, provide a playbook with tasks for building images. Ansible Container will take it from there. With Ansible Container, you are no longer limited by Dockerfile. You can now apply the power of Ansible to the image build process. About Me https://procrypt.github.io/page/about/ Mon, 01 Jan 0001 00:00:00 +0000 abhishek@linux.com (Abhishek Pratap Singh) https://procrypt.github.io/page/about/ My name is Abhishek Pratap Singh. I have the following qualities: I love programming in Go, and everything about Linux I’m extremely loyal to my family :)