avatarAngelica Lo Duca

Free AI web copilot to create summaries, insights and extended knowledge, download it at here

787

Abstract

kquote id="b27a"><p><b>I was in Madrid in the spring of 1419. I had left my troupe after Carnivale to rest through the season of Lent.</b></p></blockquote><blockquote id="a778"><p><b>The <a href="https://en.wikipedia.org/wiki/Transhumance">trashumanci</a>a passed through, heading for the higher elevations of the summer pastures.</b></p></blockquote><blockquote id="0576"><p><b>There were a few early spring lambs with them, bold youngsters who seemed apprehensive, accustomed to only their herders and worried at the sight of noisy crowds, but still curious about everything.</b></p></blockquote><blockquote id="088d"><p><b>Francisca</b></p></blockquote><p id="1779">This is a fortune teller named Francisca living in Madrid, Spain, in AD 1419. A combination of a curse and her own pow

Options

ers has allowed her to live many centuries and travel all over the world.</p><p id="9ba1">She is known as Penelope in New Orleans in the twenty-first century, where she meets a fearsome creature.</p><div id="4442" class="link-block"> <a href="https://readmedium.com/descending-into-the-otherworld-21e80595e59d"> <div> <div> <h2>Descending into the Otherworld</h2> <div><h3>I speak with a river god</h3></div> <div><p>medium.com</p></div> </div> <div> <div style="background-image: url(https://miro.readmedium.com/v2/resize:fit:320/1*[email protected])"></div> </div> </div> </a> </div></article></body>

DevOps, Data Engineering

4 Docker Options You May Not Know

How to remove an image in Docker, rebuild an image from the base image, pass some configuration files to a Docker container, and run linux/amd64 images on linux/arm64 architecture.

Photo by frank mckenna on Unsplash

In this short article, I take note of the following useful commands in Docker that I have discovered recently:

  • Removing an image in Docker
  • Rebuilding an image from the base image
  • Passing some configuration files to a Docker container
  • Attaching a terminal to a Docker container

Removing an image in Docker

You can remove a Docker image directly from Docker Desktop. However, sometimes, the image is running so you cannot remove that. Don’t worry! You can remove the image directly from the terminal as follows:

docker rmi -f <image_id>

You can take the image id from the Docker Desktop interface.

You can find more details in the Docker official documentation:

Rebuilding an image from the base image

If you want to rebuild an image from the base image, you should use the --no-cache option as follows:

docker build -t my_image .

You can find more details here:

Passing some configuration files to a Docker container

There are different ways to pass configuration files to a Docker container. Here, I suggest one possible solution, based on Docker Volumes, which permits you to map any directory in your file system to a directory in the Docker container:

docker run -v <source path>:<dest path>

You can find more details in the following article:

Attaching a terminal to a Docker container

If you want to run some command within a Docker container, you can run the following command:

docker exec -it <container_name> /bin/sh

The container must be running.

Running linux/amd64 images on linux/arm64 architecture

You can read this interesting thread on Reddit:

I have solved the problem, by using the following base image in Dockerfile:

FROM   amd64/centos:7

and then I have built the image as follows:

docker run --platform linux/amd64 --name my_container_name my_image

Summary

Congratulations! You have just learned some Docker options!

This article belongs to the Syntax Error Publication, which aims at solving your everyday issues as a developer.

If you have solved an issue and want to share how you solved it with the community, you can drop me a message and I’ll add you as a writer of the Syntax Error Publication :)

You may also be interested in…

Data Engineering
Docker
Women In Tech
DevOps
Programming
Recommended from ReadMedium