Skip to content

Instantly share code, notes, and snippets.


David Rio Deiros drio

View GitHub Profile
ruanbekker /
Created Jan 11, 2021
Python Flask with Prometheus Basic Example
$ curl http://localhost:5000/metrics
# HELP python_gc_objects_collected_total Objects collected during gc
# TYPE python_gc_objects_collected_total counter
python_gc_objects_collected_total{generation="0"} 317.0
python_gc_objects_collected_total{generation="1"} 71.0
python_gc_objects_collected_total{generation="2"} 0.0
# HELP python_gc_objects_uncollectable_total Uncollectable object found during GC
# TYPE python_gc_objects_uncollectable_total counter
python_gc_objects_uncollectable_total{generation="0"} 0.0
justinschuldt /
Last active Aug 6, 2022
Directions for setting up a RaspberryPi to act as a generic USB webcam


Webcam parts:

  • Raspberry Pi Zero W Rev 1.1
  • Raspberry Pi Camera v2 (8-megapixel)
  • Raspberry Pi High Quality Camera (12.3-megapixel)
  • Raspbian Buster Lite 2020-02-13

Webcam works with:

  • Windows 10
  • Windows 10 "Camera" app
pjobson /
Last active May 28, 2022
OpenWRT on x86_64

OpenWRT on x86_64

This is a very brief tutorial on getting OpenWRT installed on a regular computer, it assumes you know your way around Linux. If you find this and need additional details, please like, subscribe, and comm... oh wait this isn't youtube, just comment.

This is how I got OpenWRT going on a Mini ITX Intel DH67CF with an Intel G870 CPU with 4GB of RAM.

What You'll Need

  • 2 USB Sticks
  • Linux Live ISO
luk3thomas / Gemfile
Created Feb 22, 2018
Proxy to staging
View Gemfile
source ""
gem "rack"
gem "rack-proxy"
steven2358 /
Last active Aug 8, 2022
FFmpeg cheat sheet
jon-a-nygaard /
Last active Oct 30, 2020
A Highcharts example in use with Webpack and Babel.

A Highcharts example in use with Webpack and Babel.


  1. Download source files
  2. Run npm install to install all dependencies.
  3. Run npm run build to bundle app.js into bundle.js

Open application

  1. Open index.html in a browser.
DominicBreuker /
Last active Oct 14, 2021
iptables firewall

iptables cheat sheet


iptables defines tables, which group features:

  • filter: use it to filter traffic
  • nat: use it to implement NAT
  • raw: use it to define which connections iptables should track (stateful firewall)
  • mangle: use it to change some fields in packets (e.g., TTL)
  • security: use it to define access control
galexrt /
Last active Jul 5, 2022
Simple Prometheus node_exporter install script (Updated for 1.0.1)
wget "$version/node_exporter-$version.$arch.tar.gz" \
-O /tmp/node_exporter.tar.gz
mkdir -p /tmp/node_exporter
View prometheus.yml
scrape_interval: 60s
monitor: 'example'
- /etc/prometheus/config/*.rules