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
#!/bin/sh | |
TEAM=$2 | |
SCORE=$1 | |
echo $TEAM | |
echo $SCORE | |
JSON="{ \"score\": ${SCORE}, \"timestamp\":{ \".sv\":\"timestamp\" } }" | |
echo $JSON |
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
#!/bin/sh | |
WORKLOAD=$1 | |
TEAM=$2 | |
echo $WORKLOAD | |
SCORE=`./benchmark --workload $1 | awk '$0 ~ /Score: /{print $4}'` | |
JSON="{ \"score\": ${SCORE}, \"timestamp\":{ \".sv\":\"timestamp\" } }" | |
if [ -n $SCORE ]; then | |
curl -X POST -d "${JSON}" "https://ishocon-a9d93.firebaseio.com/teams/${TEAM}.json" |
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
{ | |
"global": { | |
"check_for_updates_on_startup": true, | |
"show_in_menu_bar": false, | |
"show_profile_name_in_menu_bar": false | |
}, | |
"profiles": [ | |
{ | |
"complex_modifications": { | |
"parameters": { |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
VAGRANTFILE_API_VERSION = "2".freeze | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
config.vm.box = "mvbcoding/awslinux" | |
# Mount shared folder | |
config.vm.synced_folder ".", "/vagrant/www" |
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
{ | |
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#", | |
"contentVersion": "1.0.0.0", | |
"parameters": { | |
"sshPublicKey": { | |
"type": "String", | |
"metadata": { | |
"description": "ssh public key for isucon user" | |
} | |
}, |
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
[mysqld] | |
socket=/tmp/mysql.sock | |
bind-address = 127.0.0.1 | |
port=13306 | |
user=root | |
#[mysqld_safe] | |
#socket=/usr/tmp/mysql.sock | |
#pid-file=/usr/local/var/mysql/mysql.pid | |
#log-error=/usr/local/var/log/mysql.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
[mysqld] | |
datadir=/var/lib/mysql | |
socket=/var/lib/mysql/mysql.sock | |
[mysqld_safe] | |
#log-error=/var/log/mysqld.log | |
#pid-file=/var/run/mysqld/mysqld.pid | |
[client] | |
port=3306 |
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 { | |
server_name isucon.com; | |
listen 80; | |
client_max_body_size 10m; | |
root /home/isucon/private_isu/webapp/public; | |
location ~ .*\.(html?|jpe?g|gif|png|css|js|ico|swf|inc) { | |
expires 1d; | |
# access_log off; |
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
.DEFAULT_GOAL := help | |
config: ## copy configs from repository to conf | |
@sudo cp ~/private_isu/webapp/conf/systemd/isu-ruby.service /etc/systemd/system/ | |
@sudo cp ~/private_isu/webapp/conf/nginx/nginx.conf /etc/nginx/ | |
@sudo cp ~/private_isu/webapp/conf/nginx/isucon.conf /etc/nginx/conf.d/ | |
@sudo cp ~/private_isu/webapp/conf/mysql/my.cnf /etc/mysql/ | |
@make -s nginx-restart | |
@make -s mysql-restart | |
@make -s ruby-restart |
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 bash | |
yum update | |
yum install -y git | |
# ssh passwordでログイン | |
sed -i -e 's/^PasswordAuthentication no/PasswordAuthentication yes/' /etc/ssh/sshd_config | |
/etc/init.d/sshd restart | |
# install nginx |