Skip to content

Example: Docker Carina

Lorenzo Mangani edited this page Aug 11, 2016 · 8 revisions

HOW-TO

HOMER 5 on Docker

HOMER 5 is available as an official (although still experimental) Docker image delivering a self-contained and extensible capture server container with no dependencies, useful for development and experimenting and easy to upgrade and manage.

Docker on Carina

Carina by Rackspace provides a “zero infrastructure” hosted container environment, where users no longer worry about building, managing, and updating their container environment.

DISCLAIMER:

This experimental guide is is not way connected to or endorsed by Rackspace and only leverages their free service tier. Carina is currently a BETA product and not yet suitable for production usage.


Setup Steps

This simple guide will get an HOMER 5 Capture server installed using Docker/Carina

Capture Server

  • Sign-Up for Rackspace Carina: https://getcarina.com

  • Setup your system to use Docker and Carina using the provided guide

  • Create your first cluster w/ auto-scaling from the Carina Control Panel

  • Download & Use Carina env

    • On the Carina Control Panel, click the Get Access button associated with your cluster and click Download File.
    • Save the zip file to a location on your computer. For example, the Downloads folder.
    • Unzip the file and cd to the new directory. For example, Downloads/mycluster
    • Configure the docker client, ie: source docker.env
  • Create your Homer5 container

	# docker run -tid --name homer5 -p 80:80 -p 9060:9060/udp -p 9060:9060/tcp qxip/homer-docker
	# docker ps

	docker ps
	CONTAINER ID        IMAGE               COMMAND             CREATED             STATUS              PORTS                                                                               NAMES
	9d29a7d1e1e0        qxip/homer-docker   "/run.sh"           13 hours ago        Up 13 hours         AA.BB.CC.DD:80->80/tcp, AA.BB.CC.DD:9060->9060/tcp, AA.BB.CC.DD:9060->9060/udp   0c0f7939-5ab9-401e-af63-ce8728221d0b-n1/homer5
  • Connect to Homer 5 UI
    • Point your browser at http://AA.BB.CC.DD:80
    • Login as admin/test123
-------------

Capture Agents

In order to make HOMER useful, you need data - Get your capture engines started:

  • Connect a HEP Capture Agent

    • Captagent or other HEP Agent
      • Send HEP packets to tcp/udp HEP socket at AA.BB.CC.DD:9060
    • OR -
  • Connect a HEPGEN instance to inject sample packets


Validate Setup

If all steps were successful, you should have a fully functional HOMER 5 instance running on Carina - remember their services are still in BETA so read the fineprint carefully before opening issues about HOMER ;)


Upgrades & Non-Volatile Data

To run Homer 5 docker without dropping all settings and data on each upgrade, map the mysql location to a volume when launching the docker instance:

	# docker run -tid --name homer5 -v /tmp/homermysql/:/var/lib/mysql -p 80:80 -p 9060:9060/udp -p 9060:9060/tcp qxip/homer-docker 
  • Create your Homer5 container

    • Pull the latest image
	# docker pull qxip/homer-docker
* Stop and Remove the running container
	# docker stop homer5
	# docker rm homer5
* Launch a new container using the latest image
	# docker run -tid --name homer5 -v /tmp/homermysql/:/var/lib/mysql -p 80:80 -p 9060:9060/udp -p 9060:9060/tcp qxip/homer-docker 

Troubleshooting

In case of issues with the HOMER 5 settings please consult the HOMER 5 wiki

In case of issues managing the Carina docker containers please consult the official troubleshooting guide from Carina

In case of issues with docker client/server version when using carina, try the following on the client side:

export DOCKER_API_VERSION=1.22
Clone this wiki locally