Skip to content

Instantly share code, notes, and snippets.

@debility-zz
debility-zz / converter.sh
Last active August 29, 2015 13:56
apache config converter + secure setting + php secure setting
#!/bin/sh
CONFIG_FILE="/etc/httpd/conf/httpd.conf"
DATE=`date '+%Y%m%d'`
if [ -f "${CONFIG_FILE}.orig.${DATE}" ]; then
echo '(maybe)apache config file is already converted. :-P'
exit
fi
@debility-zz
debility-zz / rd256_decode
Created November 27, 2013 10:51
rijndael-256 decode (PL/Perl)
CREATE OR REPLACE FUNCTION rd256_decode(text, text, text)
RETURNS text AS
$BODY$
use Mcrypt;
use MIME::Base64;
use utf8;
use Encode qw(encode decode);
my ($encoded, $key, $iv) = @_;
@debility-zz
debility-zz / http_load.c.patch
Created April 10, 2013 08:13
http_loadでUser-Agentを指定できるようにざっくり修正してみた
--- http_load.c.orig 2013-04-10 16:31:14.641380516 +0900
+++ http_load.c 2013-04-10 17:07:36.480199674 +0900
@@ -183,6 +183,8 @@
static char* cipher = (char*) 0;
#endif
+char* user_agent;
+
/* Forwards. */
static void usage( void );
@debility-zz
debility-zz / gist:3911223
Created October 18, 2012 11:33
mysqlcf2 log 20121018
mysqlcf2 log 20121018
MySQL Casual Talks Fukuoka #2
---
@Spring_MT はじめに
発表すること(内容じゃなくて)をcasualに
椅子もまさかりも飛んでこない
情報共有≠事業価値の欠損
@debility-zz
debility-zz / gist:3910990
Created October 18, 2012 10:55
mysql 5.5 config at RDS
mysql -ufusic -h testdb.xxxxxxxxxxxxx.ap-northeast-1.rds.amazonaws.com -p -e "show variables;" > mysql.params
Variable_name : Value
-----
auto_increment_increment : 1
auto_increment_offset : 1
autocommit : ON
automatic_sp_privileges : ON
back_log : 50
basedir : /rdsdbbin/mysql/
@debility-zz
debility-zz / gist:3017593
Created June 29, 2012 12:08
Fukinfra #3
福岡インフラ勉強会
@matsumanaさんのまとめエントリ
http://matsumana.wordpress.com/2012/06/30/%E7%AC%AC3%E5%9B%9E-%E3%82%A4%E3%83%B3%E3%83%95%E3%83%A9%E5%8B%89%E5%BC%B7%E4%BC%9A%EF%BC%A0%E7%A6%8F%E5%B2%A1%E3%81%A7lt%E3%81%97%E3%81%A6%E3%81%8D%E3%81%BE%E3%81%97%E3%81%9F/
@matsumana 脱職人芸への道
[資料]http://www.slideshare.net/matsumana0101/vol3-lt-20120629
サーバの設定配布とか同期とか
- 手作業
- rsync
@debility-zz
debility-zz / gist:3003955
Created June 27, 2012 13:04
mysqlcf log 20120627
MySQL Casual Talks Fukuoka
---
@Spring_MT はじめに
発表すること(内容じゃなくて)をcasualに
情報共有≠事業価値の欠損
---
@debility-zz
debility-zz / pom.xml.patch
Created March 17, 2012 08:44
patch for Dspace 1.7.2 + Solr 3.3.0 (DSPACE_SRC/dspace/modules/solr/pom.xml)
--- pom.xml.orig 2012-03-17 17:34:33.964667039 +0900
+++ pom.xml 2012-03-17 17:40:01.000000000 +0900
@@ -46,7 +46,7 @@
<dependency>
<groupId>org.dspace</groupId>
<artifactId>dspace-solr</artifactId>
- <version>1.4.1.1</version>
+ <version>3.3.0.0</version>
<classifier>skinny</classifier>
<type>war</type>
*** cli_helper.rb 2012-02-08 20:01:17.520514397 +0900
--- cli_helper.rb.org 2012-02-08 19:49:11.137878140 +0900
***************
*** 62,79 ****
outbuf = stdout.read
errbuf = stderr.read
}
! begin
! GC.disable
! stat = Open4::popen4(cmd, &blk)
@debility-zz
debility-zz / gist:1563184
Created January 5, 2012 01:15
apache config converter + secure setting + php secure setting
#!/bin/sh
CONFIG_FILE="/etc/httpd/conf/httpd.conf"
DATE=`date '+%Y%m%d'`
if [ -f "${CONFIG_FILE}.orig.${DATE}" ]; then
echo '(maybe)apache config file is already converted. :-P'
exit
fi