Posts

Cleaning up private docker registry

The solution to cleaning the unused docker registry layers is not straightforward, there is nothing readily available from docker. As more and more docker layers are pushed and tagged, it may be possible that there are image layers that may not be required. These unnecessary layers will consume a lot of storage space. This page describes the way to delete unused layers without disturbing the registry. I am going to explain how to clean up unused layers from docker registry using HTTP API V2 Docker HTTP API V2 More about HTTP API V2 The current version of the docker provides an option to interact with the images in the remote private registry using HTTP API version 2. Few useful Digest APIs List all the repositories available in the private registry CATALOG $ curl reg-server:5000/v2/_catalog Output ------ { "repositories" :[ "alpine","1_ubuntu_16.04" , "centos" , "centos6-build-test" , "centos6-build-qa...

How to use Jenkins docker image to run Jenkins master

How to use Jenkins docker image as a master and as a build node. In the recent past, Containerization is becoming very popular. Docker is a very prominent player in the field of containerization. Today I am going to show step by step procedure on how to use a docker image for both Jenkins master and node. Also, I am going to address a few known issues and how to find a workaround for them. In the tutorial, I will use the Jenkins version jenkins/jenkins:2.107.3. Pull the image from docker hub $ docker pull jenkins/Jenkins:2.107.3 Note that the dockerized Jenkins will use /var/jenkins_home as Jenkins home. If you want to change this you have to edit the docker file provided by the docker hub, which was used to build the image jenkins/jenkins:2.107.3. I will not cover that in the tutorial. The additional steps we are doing on top of the base image Jenkins/jenkins:2.107.3 1.      Customize the Jenkins docker image with additional packages and new users ...

Why some mobile phones does not support screen mirroring?

Image
On my Youtube channel, I have posted a video that shows how to mirror your mobile screen onto LED or LCD TV which is equipped with Wi-Fi and Miracast. To clarify what is Miracast, it is a hardware device built into your TV. If your TV is equipped with Miracast, then you don't have to use any additional dongles like Google ChromeCast to cast your mobile screen onto the TV. Please note that the Miracast feature and Google Chromecast may work differently. I got lots of comments asking questions like whether the TV is smart, whether the TV is used as a monitor with a CPU, is there any dongle connected to the TV, whether it requires internet, etc.  To clarify all these questions, it is a basic LED TV with Wi-FI and Miracst enabled. No internet, no dongle connected and it is not a smart TV. The most important question I am trying to clarify here is why some mobile phones do not have mirroring options. First, you need to understand that screen mirroring works on a Wi-Fi network...

How to install Apps in Android TV

Image
As Android TVs are becoming famous, it's obvious to know whether it will allow us to install apps on Android TV the way we do it on Android mobile and to know how to install the apps on TV. The same version of a particular app may not support all the TVs and you might not get all the apps available for Mobile. But certainly, there are plenty of apps for various purpose and it can be installed on Android TV. There are two ways to install an app on Android TV. Please note that this procedure is specific to MI Android TV. A similar procedure can be used for other Android TV. Install using .apk file The first option is to install it from a .apk file. The apk file has to be downloaded and copied into a USB using a computer. Insert the USB drive into TV, go to the location of the apk file inside the USB drive. Open the selected apk file, it will ask you to enable or trust the 'third party app' installation. If you have not done this before, got to settings and enable ...

VBA Macro to copy Excel data into MS Word table

The below code will help you to copy the MS Excel data into MS Word. The main thing to note here is, the Excel data is copied into Word in a table format. This is a very basic VBA code, you can extend this to add other features. To add this code to your excel, Open VBA editor in Excel or you can press F11. Insert a module, paste this code. Come back to excel by pressing F11 again. Under macros you can see the name of subroutine 'CopyFromExcelToWord' appearing, this is your macro. Sub CopyFromExcelToWord()    Dim objWord    Dim objDoc    Dim objRange    Dim total_rows    Dim total_cols    Dim objTable    Dim tmp_row    Dim tmp_col     total_rows = Cells(1, 10).Value     total_cols = Cells(2, 10).Value     Set objWord = CreateObject("Word.Application")   Set objDoc = objWord.Documents.Add   Set objRange = objDoc.Range   objWord.Visible = True ...

How to create MS Word document automatically with Text file

This VBA code will help you to import data from a text file and insert it into the MS word document. This is useful when you have to create a report or formats in MS Word format, reading the data from a text file. The VBA code can be extended import extra data from the text file, and also you can add additional format as per your needs. Please note that VBA macros can cause harm to your computer. First, open them in a disabled mode. To disable macros, to Developer tab, select macro security and then select Macro settings on the left side pane. In the right pane, select the second radio button, 'Disable all macros with notification'. The second option is better because it will notify you if there are any macros associated with your file. So you will not miss any document features that may be available after running a macro. But you can decide whether to allow the macros to run or not. Please click on the below link to download the MS Word Template file. You can also download...

MS Excel Currency converter VBA code

To convert numbers into text, there is no  builtin function in MS Excel as of now. Using the below VBA code you can overcome this issue. There are situations like writing a cheque leaf, printing a rent agreement, or writing contract documents that may require printing the transaction amount in the text. Make use of this code to convert numbers into text automatically.  Copy and paste this VBA code into your Excel VBA editor module. Or Insert an empty module and paste this code. Attribute VB_Name = "Module1" 'Attribute VB_Name = "Module2" ' ****  Author          : Krishna S ' ****  Tittle          : Converting Hindu Arabic Currency(Indian System) to Words ' ****  Copyright Owner : Krishna S ' ****  Description     : This utility converts currencies in Indian numbering system to words. ' ****  Limitations     : Converts only upto 10,00,00,000( Ten Crores) Function C...