-
Notifications
You must be signed in to change notification settings - Fork 15
Deployment
InfluenceMap consists of four modules.
- Kongisberg
- WebApp
- ElasticSearch
- Kibana
The dependency graph is shown below:
- Elasticsearch data e.g.
/data/elasticsearch/data. - Bingraph data e.g.
/data/bingraph.
git clone https://github.com/csmetrics/influencemap.git
cd influencemapservices:
konigsberg:
build:
context: .
dockerfile: konigsberg.dockerfile
restart: unless-stopped
volumes:
- /data/bingraph:/influencemap/bingraph # <-- !!!
environment:
GUNICORN_CMD_ARGS: --workers 32 --timeout 90 --graceful-timeout 90 --bind 0.0.0.0:8000 # <-- !!!
webapp:
build:
context: .
dockerfile: webapp.dockerfile
restart: unless-stopped
ports:
- "8001:8000" # <-- !!!
environment:
KONIGSBERG_URL: http://konigsberg:8000
ELASTICSEARCH_URL: elasticsearch:9200
GUNICORN_CMD_ARGS: --workers 32 --timeout 90 --graceful-timeout 90 --bind 0.0.0.0:8000 # <-- !!!
depends_on:
- konigsberg
- elasticsearch
elasticsearch:
image: elasticsearch:6.8.23
restart: unless-stopped
volumes:
- /data/elasticsearch/data:/usr/share/elasticsearch/data # <-- !!!
- elasticsearch_config:/usr/share/elasticsearch/config
- elasticsearch_log:/usr/share/elasticsearch/logs
environment:
- "discovery.type=single-node"
- "cluster.name=elasticsearch"
- "network.host=0.0.0.0"
- "node.master=true"
- "node.data=true"
- "ES_JAVA_OPTS=-Xms32g -Xmx32g" # <-- !!!
kibana:
image: kibana:6.8.23
restart: unless-stopped
ports:
- "8014:5601" # <--
volumes:
- kibana_config:/usr/share/kibana/config
- kibana_data:/usr/share/kibana/data
- kibana_log:/usr/share/kibana/logs
environment:
ELASTICSEARCH_URL: http://elasticsearch:9200
depends_on:
- elasticsearch
volumes:
elasticsearch_config:
elasticsearch_log:
kibana_config:
kibana_data:
kibana_log:
sudo docker compose up -dsudo docker compose restartsudo docker compose stopsudo docker compose downPortainer is a Universal Container Management System for Kubernetes, Docker/Swarm, and Nomad that simplifies container operations so you can deliver software to more places, faster
sudo docker run -d \
-p 8010:9000 \
--restart=unless-stopped \
-v /var/run/docker.sock:/var/run/docker.sock \
-v portainer_data:/data \
--name portainer \
portainer/portainer-ceWith watchtower you can update the running version of your containerized app simply by pushing a new image to the Docker Hub or your own image registry.
Watchtower will pull down your new image, gracefully shut down your existing container and restart it with the same options that were used when it was deployed initially.
sudo docker run -d \
--name watchtower \
-v /var/run/docker.sock:/var/run/docker.sock \
--restart=unless-stopped \
containrrr/watchtower \
--cleanup \
--interval 86400 \
netdata portainer umami uptime-kuma watchtower- --cleanup: Cleanup old containers and images
- --interval: Interval in seconds to check for new images, 86400 = 1 day
- netdata portainer umami uptime-kuma watchtower: List of container names to watch
sudo docker run --rm \
-v /var/run/docker.sock:/var/run/docker.sock \
containrrr/watchtower \
--run-once \
--cleanup \
netdata portainer umami uptime-kuma watchtower- --rm: Remove container after run
- --run-once: Run once and exit
Architected for speed. Automated for easy. Monitoring and troubleshooting, transformed. Slash your time to detect, troubleshoot and resolve infrastructure performance problems. With the permanently free, zero-configuration tool that makes infrastructure monitoring and troubleshooting dramatically easier for both experts and beginners.
sudo docker run -d \
--name=netdata \
--restart=unless-stopped \
-p 8011:19999 \
-v /var/run/docker.sock:/var/run/docker.sock:ro \
-v /etc/passwd:/host/etc/passwd:ro \
-v /etc/group:/host/etc/group:ro \
-v /proc:/host/proc:ro \
-v /sys:/host/sys:ro \
-v /etc/os-release:/host/etc/os-release:ro \
--cap-add SYS_PTRACE \
--security-opt apparmor=unconfined \
netdata/netdataIt is a self-hosted monitoring tool like "Uptime Robot".
sudo docker run -d \
--name uptime-kuma \
--restart=unless-stopped \
-p 8012:3001 \
-v kuma_data:/app/data \
louislam/uptime-kuma:1Umami is a simple, fast, privacy-focused alternative to Google Analytics.
Create a folder
mkdir umami
cd umamiGet init SQL script
wget https://raw.githubusercontent.com/mikecao/umami/master/sql/schema.postgresql.sqlCreate an .env file
HASH_SALT=replace-me-with-a-random-string
POSTGRES_PASSWORD=replace-me-with-a-passwordCreate a docker-compose.yaml file
version: "3"
services:
umami:
image: ghcr.io/mikecao/umami:postgresql-latest
ports:
- "8013:3000"
environment:
DATABASE_URL: postgresql://umami:${POSTGRES_PASSWORD}@db:5432/umami
DATABASE_TYPE: postgresql
depends_on:
- db
restart: unless-stopped
db:
image: postgres:12-alpine
environment:
POSTGRES_DB: umami
POSTGRES_USER: umami
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
volumes:
- ./schema.postgresql.sql:/docker-entrypoint-initdb.d/schema.postgresql.sql:ro
- db_data:/var/lib/postgresql/data
restart: unless-stopped
volumes:
db_data:Run
sudo docker compose -p umami up -d| username | admin |
| password | umami |