Skip to content

Instantly share code, notes, and snippets.

View brainstorm's full-sized avatar

Roman Valls Guimera brainstorm

View GitHub Profile
@brainstorm
brainstorm / kibana_pacemaker.json
Last active August 29, 2015 14:06
kibana_pacemaker.json
{
"title": "Pacemaker",
"services": {
"query": {
"list": {
"0": {
"query": "verb='GET'",
"alias": "GET",
"color": "#7EB26D",
"id": 0,
@brainstorm
brainstorm / Baton-dockerfile
Last active August 29, 2015 14:07
Baton Dockerfile
FROM ubuntu:12.04
ENV PGVERSION 9.3
ENV CK_DEFAULT_TIMEOUT 10
ENV IRODS_VAULT /usr/local/var/lib/irods/Vault
ENV TRAVIS_BUILD_DIR /tmp
RUN apt-cache search autotools
RUN apt-get update -qq
RUN apt-get install -qq odbc-postgresql unixodbc-dev build-essential libjansson-dev libjansson4 git wget autoconf
@brainstorm
brainstorm / Vagrantfile
Created June 24, 2015 07:58
BioStar ansible recipe
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# Every Vagrant virtual environment requires a box to build off of.
config.vm.box_url = "https://cloud-images.ubuntu.com/vagrant/trusty/current/trusty-server-cloudimg-amd64-vagrant-disk1.box"
config.vm.box = "base"
#!/bin/bash
# To use an Openstack cloud you need to authenticate against keystone, which
# returns a **Token** and **Service Catalog**. The catalog contains the
# endpoint for all services the user/tenant has access to - including nova,
# glance, keystone, swift.
#
# *NOTE*: Using the 2.0 *auth api* does not mean that compute api is 2.0. We
# will use the 1.1 *compute api*
export OS_AUTH_URL=https://pouta.csc.fi:5001/v2.0
@brainstorm
brainstorm / Dockerfile
Created September 11, 2015 09:20
SeqControl Dockerfile
FROM phusion/baseimage
RUN apt-get update && apt-get install -y wget picard picard-tools samtools bedtools
RUN apt-get autoclean
RUN cd /tmp && wget http://labs.oicr.on.ca/files/6993/file/SeqControl_0.0.1.tar.gz
RUN cd /tmp && tar xvzf SeqControl_*.tar.gz && mv SeqControl_*/* /usr/local/bin
RUN rm -rf /tmp/SeqControl_*
@brainstorm
brainstorm / slack_backup.py
Last active October 1, 2015 21:13
Saves daily chat backup for future reference in the context of a jupyter lab notebook
import os
import time
import json
import gzip
import datetime
import requests
import cPickle as pickle
from datetime import datetime
slack_token = "<SLACK_TOKEN>"
@brainstorm
brainstorm / svg_ipython.svg
Last active November 17, 2015 20:18
IPython SVG and pyveplot broken graph
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#!/bin/bash
#set -e
#set -x
# number of cycles
cycles_count=200
# first index cycle
cycle_index_start=92
# last index cycle
#!/usr/bin/env python
from toil.job import Job
def fn(job, i):
job.fileStore.logToMaster("Parent says: i is %s" % i, level=100)
return i+1
def child_worker(job, i):
job.fileStore.logToMaster("Child says: i is %s" % i, level=100)
@brainstorm
brainstorm / launch.json
Created June 9, 2016 09:59
Redirects in args for VSCode
{
"version": "0.2.0",
"configurations": [
{
"name": "GDB bcftools",
"type": "cppdbg",
"request": "launch",
"launchOptionType": "Local",
"targetArchitecture": "x64",
"program": "/Users/romanvg/dev/bcftools/bcftools",