Skip to content

Instantly share code, notes, and snippets.

@kfrancoi
kfrancoi / gist:c63c900f110581d4335d
Last active August 29, 2015 14:19
OpenWatch ES Mapping
curl -XPUT 'http://localhost:9200/INDEXNAME/_mapping/TYPENAME' -d '
{
"TYPENAME":{
"properties":{
"annotations":{
"properties":{
"count":{
"type":"long"
},
"name":{
@kfrancoi
kfrancoi / gist:ee2920c28c7be6174054
Created January 23, 2015 10:50
Mesos Master Config
# Setup
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv E56151BF
DISTRO=$(lsb_release -is | tr '[:upper:]' '[:lower:]')
CODENAME=$(lsb_release -cs)
# Add the repository
echo "deb http://repos.mesosphere.io/${DISTRO} ${CODENAME} main" | \
sudo tee /etc/apt/sources.list.d/mesosphere.list
sudo apt-get -y update
@kfrancoi
kfrancoi / meshXML_Bio2RDF.py
Last active March 28, 2021 02:46
This script parse the MESH xml dump file and turn it into an rdf triple file following partially the bio2rdf convention.
import sys
import os
import itertools
from datetime import datetime
try:
from lxml import etree
except ImportError:
import xml.etree.ElementTree as etree
import RDF