Skip to content

Instantly share code, notes, and snippets.

View jespada's full-sized avatar

jespada jespada

View GitHub Profile
@jespada
jespada / mate.py
Created December 21, 2013 18:22
test robot
import rg
class Robot:
def act(self, game):
# if we're in the center, stay put
if self.location == rg.CENTER_POINT:
return ['guard']
# if there are enemies around, attack them
for loc, bot in game.robots.iteritems():
@jespada
jespada / xmonad.hs
Created August 6, 2013 13:21
my xmonad conf
--
-- xmonad example config file.
-- https://github.com/ckoch786/Xmonad
-- A template showing all available configuration hooks,
-- and how to override the defaults in your own xmonad.hs conf file.
--
-- Normally, you'd only override those defaults you care about.
--
@jespada
jespada / haproxy.cfg
Created March 9, 2013 21:03
haproxy(1.5) + ssl + websockets (see comments on how to create a .pem file)
defaults
log global
mode http
option httplog
option dontlognull
retries 3
option redispatch
timeout connect 5s
timeout client 50s
timeout server 50s
@jespada
jespada / sensu-riemann
Created December 17, 2012 14:02
sensu + riemann
* Sensu
- As a nagios replacement basically, plus the extra goodies tha sensu has itself
(mutators, events filters , handlers, API, etc).
* Riemann
- When state tracking is needed, cause of the powerful stream processing language,
I'm planning to aggregate events from client agents running on riak nodes,
erlang queue size grow, cassandra, others, to track trends and report
on events, the idea is to report posible problems before they became critical.
@jespada
jespada / xmonad.hs
Last active October 13, 2015 14:28
xmonda config
--
-- xmonad example config file.
-- https://github.com/ckoch786/Xmonad
-- A template showing all available configuration hooks,
-- and how to override the defaults in your own xmonad.hs conf file.
--
-- Normally, you'd only override those defaults you care about.
--
@jespada
jespada / gist:3540231
Created August 30, 2012 20:34
server-debian-erlang
Erlang R14B04 (erts-5.8.5) [source] [64-bit] [smp:8:8] [rq:8] [async-threads:0] [hipe] [kernel-poll:false]
Eshell V5.8.5 (abort with ^G)
1> erlang:system_info(cpu_topology).
[{processor,[{core,[{thread,{logical,0}},
{thread,{logical,4}}]},
{core,[{thread,{logical,1}},{thread,{logical,5}}]},
{core,[{thread,{logical,2}},{thread,{logical,6}}]},
{core,[{thread,{logical,3}},{thread,{logical,7}}]}]}]
2>
name "graphite"
description "install all the 3 components for grahpite server"
run_list(
"recipe[python]",
"recipe[graphite]"
)
default_attributes(
"python" => {
@jespada
jespada / fail to start
Created August 6, 2012 19:04
data dog
Traceback (most recent call last):
File "/usr/bin/dd-forwarder", line 274, in <module>
main()
File "/usr/bin/dd-forwarder", line 271, in main
app.run()
File "/usr/bin/dd-forwarder", line 229, in run
http_server.listen(self._port)
File "/usr/lib/pymodules/python2.6/tornado/httpserver.py", line 133, in listen
self.bind(port, address)
File "/usr/lib/pymodules/python2.6/tornado/httpserver.py", line 150, in bind
@jespada
jespada / ideal ops.md
Created July 26, 2012 23:22 — forked from bhenerey/ideal ops.md
ideal ops checklist

In a perfect world, where things are done well, not just quickly, I would expect to find the following when joining the company:

Documentation

  • Accurate / up-to-date systems architecture diagram

  • Accurate / up-to-date network diagram

  • Out-of-hours support plan

  • Incident management plan

@jespada
jespada / sensu-dash
Created July 20, 2012 21:36
gem list
root@zeus:~# /opt/sensu/embedded/bin/gem list
*** LOCAL GEMS ***
addressable (2.2.8)
amqp (0.7.4)
async_sinatra (1.0.0)
bigdecimal (1.1.0)
cabin (0.4.4)
cookiejar (0.3.0)