Found 120 Articles for Docker

How to reference embedded Docker resource files using file path URL?

Hemant Sharma
Updated on 30-Jan-2023 10:00:19

2K+ Views

Introduction Embedded Docker resource files are files included in a Docker image rather than stored on the host file system or an external network location. These files can be useful for including configuration files, scripts, or other resources that are needed by the applications or processes running in the Docker container. You can reference embedded Docker resource files in several different ways, including using file path URLs. This article explains what file path URLs are and how to use them to reference embedded Docker resource files. We will also provide tips and examples to help you use file path URLs ... Read More

How to change user config in Docker tomcat 8?

Hemant Sharma
Updated on 30-Jan-2023 09:59:03

2K+ Views

Introduction In a Docker Tomcat 8 container, you may want to change the user configuration to add or modify users and roles. This modification can be useful for tasks like securing access to the Tomcat 8 instance or setting up different levels of permissions for different users. This article explains how to change the user configuration in a Docker Tomcat 8 container. We cover the steps involved in modifying the tomcat-users.xml file, building a new Docker image with the modified configuration, and running a Docker container from the new image. Prerequisites Before changing the user configuration in a Docker Tomcat ... Read More

How to access JMX interface in docker from outside?

Hemant Sharma
Updated on 30-Jan-2023 09:56:58

2K+ Views

JMX and its use in Java applications JMX (Java Management Extensions) is a Java technology that provides a way to manage and monitor Java applications. It exposes a set of APIs and MBeans (Java objects that represent resources to be managed) that can be used to monitor and control the behaviour of a Java application. JMX is commonly used in Java-based applications to monitor performance metrics such as memory usage, CPU utilization, and thread counts, as well as to manage and configure the application at runtime. Accessing JMX from outside a Docker container When running a Java application in a ... Read More

Equivalent of Docker option --config in docker-compose

Hemant Sharma
Updated on 30-Jan-2023 09:53:41

107 Views

Overview If you are using Docker Compose to define and run multi-container Docker applications, you may want to specify custom configuration files or directories for your application. Fortunately, Docker Compose provides the --config option, which allows you to do just that. The --config option is used to specify a single configuration file or a directory containing multiple configuration files for Docker Compose. To use it, you can pass it as an argument to the docker-compose command. For example − $ docker-compose --config /path/to/custom/config.yml up This command would tell Docker Compose to use the configuration file located at /path/to/custom/config.yml ... Read More

Best way to install Docker on Vagrant

Hemant Sharma
Updated on 30-Jan-2023 09:50:55

2K+ Views

Introduction Vagrant is a tool for building and managing development environments using virtualization software such as VirtualBox. It allows you to define and configure a development environment in a Vagrantfile and then spin up and tear down virtual machines quickly and easily. By using Docker and Vagrant together, you can create a flexible and reproducible development environment that is easy to set up and maintain. This article discusses the best way to install Docker on Vagrant, including the prerequisites, installation steps, and verification. Prerequisites for installing Docker on Vagrant Before installing Docker on Vagrant, you must ensure you have the ... Read More

How to start tensorflow Docker jupyter notebook?

Diksha Patro
Updated on 17-Jan-2023 18:54:37

2K+ Views

Introduction Jupyter notebooks are useful for writing, testing, and debugging code. TensorFlow is a machine learning framework that can be used with Jupyter notebooks. In this article, we will explore how to use Docker to start a TensorFlow Jupyter notebook, which will allow us to take advantage of the benefits of both of these tools. Prerequisites Before getting started, you will need to have Docker and Docker Compose installed on your machine. You can check if it is installed using the following commands − $ docker --version $ docker-compose --version You can follow the installation instructions for your ... Read More

How to rebuild Docker container on file changes?

Diksha Patro
Updated on 06-Sep-2023 12:53:52

46K+ Views

Docker is a widely used containerization solution that allows programmers to easily package and distribute software in a lightweight and portable manner. The capability of rebuilding a container once modifications are made to its files is one of Docker's key features. This can be very helpful for a number of things, like making sure that code changes are appropriately reflected in a development environment or that code updates are always reflected in a containerized application. In this article, we will go into Docker's crucial feature and examine how it may be used to rebuild a container when files are changed. ... Read More

How to manage secret values with docker-compose v3.1?

Diksha Patro
Updated on 17-Jan-2023 18:24:41

2K+ Views

Introduction As developers, we frequently need to incorporate private data into our applications, including passwords, API keys, and database credentials. Not only is it unsafe to hardcode these variables into our code or configuration files, but it can also be challenging to manage and change them when necessary. Using environment variables, which let us keep sensitive data apart from our codebase and configuration files, is one method to manage secret values. In this article, we'll look at how to maintain secret values using docker-compose v3.1 and inject them as environment variables into our containers. Prerequisites To follow along with this ... Read More

How to Improve Docker Image Size With Layers?

Diksha Patro
Updated on 17-Jan-2023 18:22:20

234 Views

In this article, we will discuss various approaches and techniques for improving Docker image size with layers, including multi-stage builds, using minimal base images, and using base images with pre-installed packages or pre-built binaries. By following these best practices, we can create smaller and more efficient Docker images that are optimized for performance and scalability. The size of Docker images with layers can be improved using a variety of methods as given below. Methods Using minimal base images Using base images with pre-built binaries Using multi-stage builds Using base images with pre-installed packages Let us discuss these methods ... Read More

How to Find the layers and layer sizes for each Docker image?

Diksha Patro
Updated on 17-Jan-2023 18:14:29

6K+ Views

Introduction By using containerization, we can quickly set up and configure our deployment environments, which helps us save time and resources. With the goal of "write once, deploy anywhere" in mind, containerization can help us streamline the process of deploying modern applications, which can be complex. Finding the layers and layer sizes for Docker images In this article, we will explore how to find the layers and layer sizes for each Docker image. This can be useful for identifying large layers that may be contributing to the overall size of the image, and for determining which layers can be removed ... Read More

Advertisements