Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀

Adrien P. crashdump

🚀
View GitHub Profile
@crashdump
crashdump / consul-ssh-configurator.py
Last active Jul 5, 2016 — forked from mattupstate/consul-ssh-configurator.py
A script to generate an SSH config from Consul's HTTP API
View consul-ssh-configurator.py
#!/usr/bin/env python3
"""
Renders a partial SSH configuration file from Nodes and Services
located in a specified Consul catalog and then merges other partial
config files into the main ~/.ssh/config file. The Consul based SSH
config follows a convention for the SSH host::
Host <prefix>_<consul-cluster-name>_<node-name>
User <ssh-user>
Hostname <consul-node-address>
@crashdump
crashdump / keybase.md
Last active Jun 5, 2019
Keybase Proof
View keybase.md

Keybase proof

I hereby claim:

  • I am crashdump on github.
  • I am adrienp (https://keybase.io/adrienp) on keybase.
  • I have a public key ASBN0dRpWA_POCJKLSZuueSZiYT4NbHMS9FQgHQ9oLWoHgo

To claim this, I am signing this object:

View zabbix_prowl.py
#!/usr/bin/python
# -*- coding: utf-8 -*-
# set expandtab ts=4 sw=4 ai
import os, sys
import time
import random
import string
import prowlpy
from twisted.python import log
@crashdump
crashdump / Template Freeswitch.xml
Created Dec 4, 2013
Freeswitch - Zabbix Monitoring
View Template Freeswitch.xml
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>2.0</version>
<date>2013-12-04T16:01:36Z</date>
<groups>
<group>
<name>Templates</name>
</group>
</groups>
<templates>
@crashdump
crashdump / Template CouchDB.xml
Last active Jul 5, 2018
CouchDB / BigCouch - Zabbix Monitoring
View Template CouchDB.xml
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>2.0</version>
<date>2013-12-03T16:57:07Z</date>
<groups>
<group>
<name>Templates</name>
</group>
</groups>
<templates>
@crashdump
crashdump / Template Kamailio.xml
Last active May 25, 2021
Kamailio - Zabbix Monitoring
View Template Kamailio.xml
<?xml version="1.0" encoding="UTF-8"?>
<zabbix_export>
<version>2.0</version>
<date>2013-12-03T11:38:27Z</date>
<groups>
<group>
<name>Templates</name>
</group>
</groups>
<templates>
@crashdump
crashdump / .vimrc
Created Nov 26, 2013
vimrc /w vundle
View .vimrc
" Install me
" git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle
" wget -O ~/.vimrc https://raw.github.com/crashdump/tasty-debian/master/files/vim/vimrc
" vim +BundleInstall +qall
set nocompatible
filetype off
syntax on
@crashdump
crashdump / epilepsy.c
Created Oct 9, 2013
I use this on a monitoring screen to get my attention: It make the screen flash multiples times (X11)
View epilepsy.c
#include <unistd.h>
#include <X11/X.h>
#include <X11/Xlib.h>
#include <strings.h>
#include <memory.h>
#include <stdlib.h>
#include <stdio.h>
/*
* 2013/10/09. Adrien Pujol.
View ip6tables
### BEGIN INIT INFO
# Provides: firewall
# Required-Start: $network
# Required-Stop: $network
# Default-Start: S 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Firewall (ipv6) rules
# Description: Simple script to initialise an ip6tables firewall
### END INIT INFO
View iptables
### BEGIN INIT INFO
# Provides: firewall-ipv4
# Required-Start: $network
# Required-Stop: $network
# Default-Start: S 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Firewall rules
# Description: Simple script to initialise an iptables firewall
### END INIT INFO