Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/shimizukawa/fig-practices

fig practices
https://github.com/shimizukawa/fig-practices

Last synced: about 1 month ago
JSON representation

fig practices

Awesome Lists containing this project

README

        

================================================================================
fig practice: Python FlaskApp + Nginx + Fluentd + ElasticSearch + Kibana4 Beta3
================================================================================

Bootstrap
==========

1. install vagrant + virtualbox.
2. execute::

local $ vagrant up # provisioner make docker environment
local $ vagrant ssh
ubuntu $ sudo su
ubuntu # cd /vagrant
ubuntu # fig up

3. browse to:

- http://192.168.10.10/ to see FlaskApp view
- http://192.168.10.10:5601/ to see Kibana4 view

Used containers
===============

- `python:2.7`_:
to execute FlaskApp

- `redis:2`_:
KeyValue storage for FlaskApp

- `nginx:latest`_:
Web frontend for FlaskApp and Kibana4

- `shimizukawa/fluentd:latest`_:
simple fluentd to collect nginx log and transfer it to elasticsearch.

- `devdb/kibana:latest`_:
Kibana4 beta3 with ElasticSearch

.. _python:2.7: https://registry.hub.docker.com/_/python/
.. _redis:2: https://registry.hub.docker.com/_/redis/
.. _nginx:latest: https://registry.hub.docker.com/_/nginx/
.. _shimizukawa/fluentd:latest: https://registry.hub.docker.com/u/shimizukawa/fluentd/
.. _devdb/kibana:latest: https://registry.hub.docker.com/devdb/kibana

Container Structures
====================

Browser access flow::

Browser
|
|
v
Nginx ----> FlaskApp ---> Redis
\
\
\
------------------\
\
\
fluentd kibana4
elasticsearch

Log data flow::

Nginx FlaskApp Redis
|
|access.log
|
|
v (fluentd-elasticsearch-plugin)
fluentd -------------------------> elasticsearch
kibana4