http://tinkerman.cat/rpi3_iot_server.pdf (Catalan)
- download the latest image
--- | |
title: "Codebook template" | |
author: "Your name here" | |
date: "The date here" | |
output: | |
html_document: | |
keep_md: yes | |
--- | |
## Project Description |
trait Expr | |
case class Number(n:Int) extends Expr | |
case class Sum(n:Expr,m:Expr) extends Expr | |
case class Var(n:String) extends Expr | |
case class Prod(n:Expr,m:Expr) extends Expr | |
def eval(e:Expr):Int = e match { | |
case Number(n) => n | |
case Sum(x,y) => eval(x) + eval(y) | |
case Prod(x,y) => eval(x) * eval(y) |
// sorting a list with a custom method of sorting | |
val x = 7::2::5::Nil; | |
val y = 1::2::List(3,4,Nil)::5::Nil; | |
x.size | |
y.size | |
def insert(x:Int, xs:List[Int]):List[Int] = xs match { | |
case List()=> List(x) |
GET _cat/ | |
GET /_cluster/health?h=status | |
PUT /index-2016.06.06 | |
{ | |
"settings": { | |
"number_of_shards" : 1, | |
"number_of_replicas" : 0 |
# install using steps https://docs.docker.com/engine/installation/linux/docker-ce/fedora/#install-using-the-repository | |
# erron while "sudo docker run hello-world" | |
# The error: Service lacks both ExecStart= and ExecStop= setting | |
# Solved with post https://success.docker.com/KBase/Using_systemd_to_control_the_Docker_daemon | |
#Solution: | |
sudo systemctl edit docker | |
[Service] | |
ExecStart= |
#start docker daemon (on viperr) | |
systemctl restart docker | |
#start bash in docker | |
docker exec -ti container_name bash | |
#docker informations | |
docker -D info |
#create an aliast for squash all commits and use it | |
git config --global alias.squash-all '!f(){ git reset $(git commit-tree HEAD^{tree} -m "${1:-A new start}");};f' | |
git squash-all "First commint - one commit" | |
#add tag | |
git tag {TAG_NAME} | |
git push origin {BRANCH_NAME} --tags | |
# Liste des tags en local: |
http://tinkerman.cat/rpi3_iot_server.pdf (Catalan)
### SOURCES #######################################################################""" | |
# https://www.influxdata.com/blog/running-the-tick-stack-on-a-raspberry-pi/ | |
# https://makemypi.wordpress.com/2018/02/19/iot-with-influxdb-telegraph-and-grafana-on-the-raspberry-pi-3/ | |
# https://thingsmatic.com/2017/03/02/influxdb-and-grafana-for-sensor-time-series/ | |
# https://github.com/opendata-stuttgart/mqtt-stack/blob/master/howto_setup_tick_stack.md | |
# https://gist.github.com/fragolinux/c9b0025f831d1c9edcdf049d920d34ad | |
## https://bentek.fr/influxdb-grafana-raspberry-pi/ | |
## http://ticksurraspberrypi3.blogspot.com/ | |
## https://www.influxdata.com/integration/mqtt-monitoring/ | |
## https://github.com/fg2it/grafana-on-raspberry |
#Queue | |
https://www.rabbitmq.com/mqtt.html | |
#Boket MQTT | |
Mosquitto MQTT Broker | |
# Check elements in queue | |
MQTT Lens (chrome plugin) | |