zzzzz icon indicating copy to clipboard operation
zzzzz copied to clipboard

Provide a Dockerfile

Open jdrago999 opened this issue 9 years ago • 2 comments

Many projects include a Dockerfile which allows other folks to quickly run the project in a controlled environment.

Provide one for this project.

Tasks:

  • select base OS.
  • discover system packages which are required for this package to run.
  • define setup process.
  • provide working examples (copy-n-paste-ready) of this package in action.
    • if API keys or authentication tokens, etc are required, then provide detailed instructions on how to acquire them, and where they should be applied for a successful run of this software.

jdrago999 avatar May 02 '16 17:05 jdrago999

+1 Dockerfile would make it much better.

ondrejmo avatar Aug 14 '16 17:08 ondrejmo

I hardly understand why one would use a docker container for this project since you have to store logs in your hdd (not the container's one) and process them not in real time, so after the execution. So, just starting with this, we are allocating memory, cpu and resources in general, for nothing more.

By the way, I made a couple of docker containers: pielco11/zzzzz:original and pielco11/zzzzz:es. The first one is the original repo, to use it do:

  1. docker pull pielco11/zzzzz:original
  2. docker run -v /full/path/to/SECRETS.txt:/zzzzz/SECRETS.txt pielco11/zzzzz:original
  3. to watch the log: first find the container id of the corresponding image with docker container ls and than run docker logs -f.

The second one is a more interesting one with a little sense of existence. It requires elasticsearch and nothing less than kibana. Why them? Just look in my fork, there you'll see (for every question don't hesitate to ask). I decided to use the default networking mode (bridge) so what you will have to do is:

  1. docker pull pielco11/zzzzz:es;
  2. Open $elasticsearch_home_path/config/elasticsearch.yml and add network.host: 127.0.0.1 and http.host: 0.0.0.0, so that elasticsearch will expose its APIs over http and let them accessible from "everywhere";
  3. Run ifconfig and look for docker, if you have more docker interfaces (docker1, docker2,...) and don't know what to use just run docker run --rm -it ubuntu:trusty bash -il and than route and look for Gateway (since every container is running, by default, with bridge net mode, the gateway is one, and is your interface that let you communicate with docker containers). It will be likely 172.12.0.1;
  4. Finally run docker run -v /full/path/to/SECRETS.txt:/zzzzz/SECRETS.txt pielco11/zzzzz:es ip where ip is the one that you previously found.

Again, for every question don't hesitate to ask. If I'm missing your point, please let me know.

pielco11 avatar Dec 30 '17 19:12 pielco11