Skip to content

Instantly share code, notes, and snippets.

View matsumotory's full-sized avatar
:octocat:
manager now

Ryosuke Matsumoto / @matsumotory matsumotory

:octocat:
manager now
View GitHub Profile
# for status code
<match norikra.query.status.**>
type json_expander
subtype growthforecast
remove_prefix norikra.query.status
<template>
gfapi_url http://127.0.0.1:5125/api/
graph_path ${data[real_hostname]}/${data[hostname]}/${key_name}
name_keys count_2xx,count_3xx,count_4xx,count_5xx
Verifying that +matsumotory is my blockchain ID. https://onename.com/matsumotory
@matsumotory
matsumotory / build_config.rb
Last active July 4, 2016 15:40
mruby error
MRuby::Build.new do |conf|
# load specific toolchain settings
# Gets set by the VS command prompts.
if ENV['VisualStudioVersion'] || ENV['VSINSTALLDIR']
toolchain :visualcpp
else
toolchain :gcc
end
location /rack_base2 {
mruby_content_handler_code '
class RackTest
def call(env)
[200, [["x-hoge", "foo"], ["x-foo", "hoge"]], ["rack", " body"]]
end
end
run RackTest.new
';
}
#include <stdio.h>
#include "mruby.h"
#include "mruby/array.h"
int main()
{
int i;
const char *cary[] = {"hoge", "fuga", "foo"};
ls -l aaa
debug_opt = (ENV["TRUSTERD_TYPE"] == "production") ? false : true
s = HTTP2::Server.new({
:port => 80,
:server_name => SERVER_DESCRIPTION,
:document_root => "/trusterd-htdocs",
:worker => "auto",
:run_user => "trusterd",
# listen ip address
@matsumotory
matsumotory / build_config.rb
Last active August 29, 2015 14:20
Cross compile mruby-simplehttpserver for linux on MacOSX
MRuby::Build.new do |conf|
toolchain :gcc
conf.gembox 'full-core'
conf.gem :github => 'matsumoto-r/mruby-simplehttpserver'
conf.gem :github => 'iij/mruby-io'
conf.gem :github => 'iij/mruby-socket'
conf.gem :github => 'iij/mruby-pack'
conf.gem :github => 'mattn/mruby-http'
s = HTTP2::Server.new({
# 色々
})
s.set_access_checker_cb {
@matsumotory
matsumotory / nginx.conf
Created February 19, 2015 15:20
MaxRequestsPerChild for nginx using ngx_mruby
error_log stderr notice;
daemon off;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;