If you are a student of 0xAcademy, you only need to do the Compulsory part.
- Google Chrome Browser
- Metamask Plugin on Chrome
- Registered wallet/account on Ropsten
- Request tokens from Ropsten Faucet
If you are a student of 0xAcademy, you only need to do the Compulsory part.
# redirect http to https | |
set $redirect ""; | |
if ($http_x_forwarded_proto != 'https') { | |
set $redirect "1"; | |
} | |
if ($http_user_agent !~* ELB-HealthChecker) { | |
set $redirect "${redirect}1"; | |
} | |
if ($http_host ~ "your-nifty-domain.com") { | |
set $redirect "${redirect}1"; |
# Put this into lib/tasks | |
require 'rubygems' | |
require 'bundler' | |
require 'aws-sdk' | |
require 'socket' | |
require 'os' | |
if Rails.env.development? |
Located in alphabetical order (not prefer)
C
ab
), also designed as a more modern replacement, written in C
golang
)Prerequisites:
Software components used:
AWS_ACCESS_KEY_ID="YOURAWSACCESSKEYID" | |
AWS_SECRET_KEY="YOURAWSSECRETKEY" | |
EC2_REGION=$(wget -q -O - http://169.254.169.254/latest/dynamic/instance-identity/document | grep region | awk -F\" '{print $4}') | |
EC2_INSTANCE_ID=$(wget -q -O - http://169.254.169.254/latest/meta-data/instance-id) | |
EC2_CLOUDWATCH_NAMESPACE='WebService' | |
NGINX_CONNECTIONS=$(wget -q -O - http://127.0.0.1/nginx_status | grep 'connections' | awk '{print $3}') | |
/usr/bin/mon-put-data --region \"$EC2_REGION\" --metric-name HttpConnections --namespace \"$EC2_CLOUDWATCH_NAMESPACE\" --dimensions \"InstanceId=$EC2_INSTANCE_ID\" --value \"$NGINX_CONNECTIONS\" -I \"$AWS_ACCESS_KEY_ID\" -S \"$AWS_SECRET_KEY\" |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
Originally published in June 2008
When hiring Ruby on Rails programmers, knowing the right questions to ask during an interview was a real challenge for me at first. In 30 minutes or less, it's difficult to get a solid read on a candidate's skill set without looking at code they've previously written. And in the corporate/enterprise world, I often don't have access to their previous work.
To ensure we hired competent ruby developers at my last job, I created a list of 15 ruby questions -- a ruby measuring stick if you will -- to select the cream of the crop that walked through our doors.
Candidates will typically give you a range of responses based on their experience and personality. So it's up to you to decide the correctness of their answer.
Changes:
this version includes backport of Greg Price's patch for speedup startup http://bugs.ruby-lang.org/issues/7158 .
ruby-core prefers his way to do thing, so that I abandon cached-lp and sorted-lf patches of mine.
this version integrates 'array as queue' patch, which improves performance when push/shift pattern is heavily used on Array.
This patch is accepted into trunk for Ruby 2.0 and last possible bug is found by Yui Naruse. It is used in production* for a couple of months without issues even with this bug.
#!/usr/bin/env ruby | |
Dir.chdir File.join(__FILE__, "../..") | |
unless ENV['EDITOR'] | |
puts "No EDITOR found. Try:" | |
puts "export EDITOR=vim" | |
exit 1 | |
end | |
unless ARGV.count == 2 |