Install with Dockerfile

To use NCache from the pulled image, you need to create containers which host
NCache. Before proceeding to that, you need to ensure that transparent network
has been configured.

Configure Transparent Network

Transparent network uses IPs from host network and each container is assigned a
separate virtual NIC. This network best suits network configuration needed for
NCache. Each container acts as a separate node and can communicate across hosts
on the same network, meaning that the NCache cluster can be managed anywhere
from that network. Containers attached to a network created with the transparent
driver will be directly connected to the physical network. IPs from physical
network can be assigned statically or dynamically.

Important

It is highly recommended to use static IPs for each container as all future connections will take place using this IP. These IPs should exist in the IP range specified in the transparent network created.

The following docker network
create
command creates a transparent network called transNet which contains subnet
20.200.20.0/24 and specifies the gateway as 20.200.20.1. You can change the
values according to your own environment.

Create Container from Image

Once the NCache image is pulled, you can create containers which host NCache and
use them as cache servers or clients (according to the image).

The container can be created with either docker
run or docker
create command,
the difference being docker run starts the container when it is created.

Important

It is highly recommended to use static IPs for each container as all future connections will take place using this IP. These IPs should exist in the IP range specified in the transparent network created.

Note that while creating containers, the image specified should exist locally.
If not, the image is then fetched from Docker Hub if the name of the repository
is specified.

Note

NCache Community container is created in Evaluation trial mode. You can activate NCache license once you purchase it.

NCache 4.9 Community Server

The following commands create the containers named ncache-com-server-01 and
ncache-com-server-02 in the shipped image
(alachisoft/ncache:community-server-4.9) in detached mode using the configured
transparent network:

The following commands create the containers named ncache-oss-server-01 and
ncache-oss-server-02 in the shipped image
(alachisoft/ncache:opensource-server-4.9) in detached mode using the configured
transparent network: