Skip to content

Instantly share code, notes, and snippets.

@jmrodri
jmrodri / gist:8698254
Created January 29, 2014 22:14
bz 1021443
diff --git a/src/subscription_manager/gui/registergui.py b/src/subscription_manager/gui/registergui.py
index 521109b..65836ba 100644
--- a/src/subscription_manager/gui/registergui.py
+++ b/src/subscription_manager/gui/registergui.py
@@ -29,6 +29,7 @@ import gtk.glade
import rhsm.config as config
from rhsm.utils import ServerUrlParseError
+from rhsm.connection import GoneException
@jmrodri
jmrodri / zdrain
Created May 1, 2014 18:35
zdrain - Modified qpid drain program
#!/usr/bin/env python
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
### Keybase proof
I hereby claim:
* I am jmrodri on github.
* I am jmrodri (https://keybase.io/jmrodri) on keybase.
* I have a public key whose fingerprint is BF6F 6F18 8467 5375 4CBB 1DDF BC96 79ED 89ED 8983
To claim this, I am signing this object:
@jmrodri
jmrodri / addmode
Last active August 29, 2015 14:16
# Copyright 2013 jesus m. rodriguez
#!/bin/sh
xres=$1
yres=$2
fullmodeline=$(cvt 1366 768 | grep Modeline | awk '{$1=""; print $0}')
modeline=$(echo $fullmodeline | awk '{print $1}')
monitors=$(xrandr | grep " connected " | awk '{print $1}')
matches=$(echo $monitors | gawk '{print NF}')
@jmrodri
jmrodri / show_deployment.sh
Created May 8, 2015 01:25
show_deployment.sh
curl -k -s -u admin:changeme -H "Accept: application/json" -X GET https://192.168.121.144:443/fusor/api/v2/deployments/$1 | python -mjson.tool
@jmrodri
jmrodri / deploy.sh
Created May 8, 2015 01:27
deploy.sh
curl -k -s -u admin:changeme -H "Accept: application/json" -H "Content-Type: application/json" -X PUT https://192.168.121.144:443/fusor/api/v2/deployments/$1/deploy?skip_content=true | python -mjson.tool
declare -a MACHINES=('192.168.121.25' '192.168.121.34' '192.168.121.144' '192.168.252.21')
declare -a LOCAL_PORTS=(9009 9010 9011 9012)
declare -a REMOTE_PORTS=(3000 443 443 443)
USER=vagrant
LPORT=
RPORT=
IPADDR=
main ()
bin/rho auth list
Config Encryption Password:
name type username password key
-------------- ---- -------- -------- ---
foo ssh jmrodri ********
key ssh_key root ******** *******
key1 ssh_key jmrodri ******** *******
key2 ssh Administrator ********
kiss my ass ssh biteme ********
bin/rho profile list
Config Encryption Password:
name range ports auth
-------------- ------------------------- --------------- ----
prof1 ['127.0.0.1'] [22, 2222, 5402]
prof2 ['192.168.0.1 - 192.168.0.243'] [22]
profiles:
name:
this is a really long name
auths:
foo
this is a long ass name
ports:
22