How to Extract the Files in a Docker Image
Ever needed to extract the files in a Docker container?
Docker provides the save sub-command.
Exporting Docker files into a Tar Archive
The examples …
Read Article →In-depth guides, insights, and best practices for modern software engineering
Ever needed to extract the files in a Docker container?
Docker provides the save sub-command.
The examples …
Read Article →If you’ve run into this dreaded error:
Error response from daemon: No such image:
Then you can solve it as follows:
Perform a docker pull …
When you launch an EC2 instance, you can use the user-data to bootstrap a instance creation script.
We can use the following code to start a web …
Read Article →Ever searched for kubectl update config from aws eks and needed a quick result?
Make sure that you have valid AWS …
Read Article →Java provides many ways to generate random strings.
public void generatingRandomAlphanumericString_ApacheCommons() { …
Read Article →
Python gives the ability to generate random strings out of the box, by using a combination of the string and random modules.
import string
import …
Read Article →
If you need to generate a random number or string in Terraform, then you can use the following:
This is useful when you need unique names for …
Read Article →If you have received the following error while trying to issue commands to kubectl:
Unable to connect to the server: dial tcp: lookup
Then it may be …
Read Article →Storing Terraform states files locally is not recommended. Instead you should use a backend such as as S3 from AWS.
To do this, you just need to add …
Read Article →If you have come across the following error:
ZipArchive extension: <strong>disabled/not installed</strong>
This just means that …
Read Article →We have been searching for all the neighboring points in a Cartesian coordinate system. As we know each point in a coordinate system has …
Read Article →The prime number sequence starts with: 2,3,5,7,11,13,17,19.... Notice that 2 is in position one.
3 occupies position two, which is a …
When you first try and push to a git repository, you may get the following error message:
error: src refspec master does not match any.
error: failed …
Read Article →
In this challenge, you will be given a number n (n > 0) and your task will be to return the smallest square number N (N > 0) such …
The purpose of this challenge is to write a higher-order function returning a new function that iterates on a specified function a given …
Read Article →The depth of an integer n is defined to be how many multiples of n it is necessary to compute before all 10 digits have appeared at …
Implement a function reverse_list that takes a singly-linked list of nodes and returns a matching list in the reverse order.
Assume the …
Read Article →In this challenge, you will be given a series of times at which an alarm goes off. Your task will be to determine the maximum time …
Read Article →Given an integer n return "odd" if the number of its divisors is odd. Otherwise, return "even".
Note: big inputs …
Read Article →In this challenge, you will be given an integer n, which is the number of times that is thrown a coin. You will have to return an array …
Read Article →Hereinafter, [space] refers to " ", [tab] refers to "\t", and [LF] refers to "\n" for illustrative …
You have an array of integers and have a frog at the first position
[Frog, int, int, int, ..., int]
The integer itself may tell you the …
Read Article →Write the following function:
def area_of_polygon_inside_circle(circle_radius, number_of_sides):
It should calculate the area of a …
Read Article →You are developing an image hosting website.
You have to create a function for generating random and unique image filenames.
Create a …
Read Article →