This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import requests | |
| services = ( | |
| ("http://httpbin.org/get", 'POST'), | |
| ("http://httpbin.org/get", 'POST'), | |
| ("http://httpbin.org/get", 'POST'), | |
| ("http://httpbin.org/get", 'POST'), | |
| ("http://httpbin.org/get", 'POST'), | |
| ("http://httpbin.org/get", 'POST') | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| import urllib2 | |
| import json | |
| url = "http://localhost:8080/api/metrics" | |
| res = urllib2.urlopen(url).read() | |
| json_res= json.loads(res) | |
| print json_res['threads'] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def sourceProps = new Properties() | |
| def destProps = new Properties() | |
| def diffProps = new Properties() | |
| file("source.properties").withInputStream { sourceProps.load(it) } | |
| file("dest.properties").withInputStream { destProps.load(it) } | |
| task diff { | |
| doFirst { | |
| def sourceKeys = sourceProps.stringPropertyNames(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| yum install ntp | |
| chkconfig ntpd on | |
| ntpdate pool.ntp.org | |
| service ntpd start |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # tcpdump standard | |
| sudo tcpdump -nvvv -i any -c 20 'port 9090' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo apt-get install libxml2-dev libxslt1-dev | |
| sudo pip install lxml | |
| sudo apt-get install libjpeg-dev | |
| sudo apt-get install libsasl2-dev python-dev libldap2-dev libssl-dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| interface HsmCrypto { | |
| public String encrypt(String keyLabel, String data) | |
| public String decrypt(String keyLabel, String data) | |
| public String sign(String keyLabel, String data) | |
| } | |
| class HsmCryptoSafenet implements HsmCrypto { | |
| private CryptoBo crypto; | |
| private HsmCryptoConfig config; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| git log --since='last month' --pretty=format:'%h;%an;%ad;%s' --author='Ionut Colceriu' > ~/log.csv |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "nodes": [ | |
| {"id": "Myriel", "group": 1}, | |
| ], | |
| "links": [ | |
| {"source": "Napoleon", "target": "Myriel", "value": 1}, | |
| {"source": "Mlle.Baptistine", "target": "Myriel", "value": 8}, | |
| ] | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <meta charset="utf-8"> | |
| <style> | |
| .links line { | |
| stroke: #999; | |
| stroke-opacity: 0.6; | |
| } | |
| .nodes circle { |