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 ports, offset = [], 0 | |
# ... | |
Net::SSH.start(hostname, user, :forward_agent => true, :verbose => :warn) do |ssh| | |
ports.each do |port| | |
ssh.forward.local port + offset, 'localhost', port | |
end | |
# loop, with an event loop every 0.1s, until Ctrl-C is pressed | |
puts "[Ctrl-C] to terminate..." |
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
class SOAPHelper | |
class << self | |
def data_from(data, wrapper) | |
data[wrapper] || data | |
end | |
def items_from(set) | |
unless set && set.item | |
nil | |
else |
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
# Set default values for all following accounts. | |
defaults | |
host smtp.gmail.com | |
port 587 | |
timeout off | |
protocol smtp | |
domain localhost | |
# /usr/bin/msmtp --version |
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
server { | |
include extra/proxy.conf; | |
include mime.types; | |
listen 80; | |
server_name blog.DOMAIN.NAME; | |
access_log logs/LOGFILE-access.log; | |
###error_log logs/LOGFILE-error.log debug; |
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
server { | |
include extra/proxy.conf; | |
include mime.types; | |
listen 80; | |
server_name wiki.DOMAIN.NAME; | |
access_log logs/LOGFILE-access.log; | |
###error_log logs/LOGFILE-error.log debug; | |
error_log logs/LOGFILE-error.log; |
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
# can't set this here! | |
###proxy_redirect default; | |
proxy_set_header Host $host; | |
proxy_set_header X-Real-IP $remote_addr; | |
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; | |
#client_max_body_size 10m; | |
#client_body_buffer_size 128k; |
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
upstream fastcgi_cluster { | |
# sticky by IP | |
###ip_hash; | |
# max_fails=3 fail_timeout=15s weight=2 | |
# down backup | |
server 127.0.0.1:PORT-1; | |
server 127.0.0.1:PORT-2; | |
server 127.0.0.1:PORT-3; | |
} |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Disabled</key> | |
<false/> | |
<key>Label</key> | |
<string>logrotate</string> | |
<key>ProgramArguments</key> |
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
# ~/.curlrc | |
ciphers=rsa_aes_128_sha |
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
--- a/wordpress/wp-includes/class-http.php | |
+++ b/wordpress/wp-includes/class-http.php | |
@@ -1160,6 +1160,12 @@ class WP_Http_Curl { | |
curl_setopt( $handle, CURLOPT_RETURNTRANSFER, true ); | |
curl_setopt( $handle, CURLOPT_SSL_VERIFYHOST, ( $ssl_verify === | |
curl_setopt( $handle, CURLOPT_SSL_VERIFYPEER, $ssl_verify ); | |
+ | |
+ // GitHub fail | |
+ // curl -vvv https://api.github.com/gists/2166671 | |
+ // http://blog.cantremember.com/one-line-fix-wordpress-and-git |