Index ¦ Archives ¦ Atom > Category: infrastructure ¦ Atom

Brief overview of using consul tags

consul allows a service to associate itself with tags. These are arbitrary metadata that can be associated with the service and can be used for different purposes. Below I outline a few examples of making use of tags and discuss some related topics.

Use case #1: Dedicated service instances based …

Add an additional host entry to docker container


Let's say a program in a container should be able to resolve a custom hostname.


When using docker run:

$ sudo docker run --add-host -ti python bash
Unable to find image 'python:latest' locally
latest: Pulling from library/python
Digest: sha256:eb20fd0c13d2c57fb602572f27f05f7f1e87f606045175c108a7da1af967313e
Status …

User-defined networks in Docker for inter-container communication


Let's say a program in a container wants to communicate with a service running in another docker container on the same host. The current recommended approach to do so is using a user-defined network and avoid using links.


Docker user defined network

Create an user-defined network and run both (or as many …

Data only Docker containers

In this post, we shall take a look at the idea of data only containers - containers whose sole purpose is to exist on the docker host so that other containers can have portable access to a persistent data volume.

Why do we need a persistent data volume?

We will experiment …

Mounting a docker volume on SELinux enabled host

My workflow with docker usually involves volume mounting a host directory so that I can read and write to the host directory from my container as a non-root user. On a Fedora 23 host with SELinux enabled, this is what I have to do differently:

Use: -v /var/dir1:var …

© Amit Saha. Built using Pelican. Theme by Giulio Fidente on github.