Skip to content

Instantly share code, notes, and snippets.

View devvesa's full-sized avatar
🐢
Working from home

Jaume Devesa devvesa

🐢
Working from home
  • Midokura
  • Barcelona
  • 09:20 (UTC -12:00)
View GitHub Profile
@devvesa
devvesa / start_app.py
Last active August 21, 2020 10:11
Tornado main loop
from tornado.web import AsyncIOMAinLoop
import asyncio
def make_application(
handlers: Handlers = None,
settings: str = "settings.py",
command_line_parsing: bool = True,
validation_function=None,
) -> tornado.web.Application:
global ENABLE_PROFILER
@devvesa
devvesa / keybase.md
Last active March 10, 2018 09:57
keybase.md

Keybase proof

I hereby claim:

  • I am devvesa on github.
  • I am devesa (https://keybase.io/devesa) on keybase.
  • I have a public key ASC-lCrInLEgBlcAcCMs5-M3y_cIXQtAHwViMrVq5hcx_go

To claim this, I am signing this object:

@devvesa
devvesa / keybase.md
Created June 15, 2016 10:41
Keybase proof

Keybase proof

I hereby claim:

  • I am jdevesa on github.
  • I am devvesa (https://keybase.io/devvesa) on keybase.
  • I have a public key ASDI3BnAoAIzJrVEGiiVKdg-0eZvVjm_spC4_l5FLwEioAo

To claim this, I am signing this object:

@devvesa
devvesa / fuel_role_validator
Created July 6, 2015 10:50
Fuel Role Validator
{'$schema': 'http://json-schema.org/draft-04/schema#',
'description': 'Serialized Role object',
'properties': {'id': {'type': 'integer'},
'meta': {'properties': {'conflicts': {'description': 'Specify which roles conflict this one.',
'type': 'array'},
'description': {'description': 'Short description of role functionality',
'type': 'string'},
'has_primary': {'description': 'During orchestration this role will be splitted into primary-role and role.',
'type': 'boolean'},
'limits': {'properties': {'condition': {'type': 'string'},
@devvesa
devvesa / proposal.mkd
Last active August 29, 2015 14:17
MidoNet Neutron Plugin packaging guidelines

Packaging guidelines

This documents explains the packaging procedures and naming conventions for the networking-midonet MidoNet's Neutron plugin.

Naming Guidelines

Package name

fwp_db.audited fwp['audited'] Result: fwp['audited']
==========================================================
True True False
True False False
False True True
False False False
@devvesa
devvesa / git_tips.md
Created April 9, 2014 15:23
Git commands tips

Git Tips Cheatsheet

Useful git commands for lazy people

Search for commits when you know the content of a line

git log -S<string> path/to/file
@devvesa
devvesa / ansible.cfg
Created February 27, 2014 16:59
Ansible cookbooks for devstack
[ssh_connection]
ssh_args=-o ForwardAgent=yes
@devvesa
devvesa / openstack_defaults.md
Created February 19, 2014 10:36
Openstack Defaults

Openstack Defaults Reference

Default configuration options in openstack.

Ports

Keystone Admin Port          =>    35357     
Keystone 'Token' Port        =>     5000     
Neutron                      =>     9696    

Nova => 8774

@devvesa
devvesa / treenode.py
Created January 21, 2014 17:10
Midokura homework
#!/usr/bin/env python
# Implement the 'findFirstCommonAncestor' method that given another TreeNode
# finds the first (deepest in the tree) common ancestor of 'this' TreeNode and
# the one passed to the method. Assume that each TreeNode is a node in a
# binary tree. You may add methods but not data members to the TreeNode class.
#
# Solution
#
# To approach this exercise I create two lists with the paths of the two