This file contains 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
require 'fileutils' | |
Dir['test/**.jpg'].each do |f| | |
dirname = File.dirname(f) | |
filename = File.basename(f) | |
new_filename = filename.gsub(/IMG_([0-9]+)/, "reU-") | |
puts "#{dirname}/#{filename} => #{dirname}/#{new_filename}" | |
FileUtils.mv "#{dirname}/#{filename}", "#{dirname}/#{new_filename}" | |
end |
This file contains 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
ShopifyAPI::Customer.find_all do |customer| | |
# do something with the customer | |
end | |
ShopifyAPI::Order.find_all(:status => :any) do |order| | |
# do something with the order | |
end | |
ShopifyAPI::Product.find_all(:limit => 250) do |order| | |
# do something with the product |
This file contains 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
### Keybase proof | |
I hereby claim: | |
* I am ianneub on github. | |
* I am ianneub (https://keybase.io/ianneub) on keybase. | |
* I have a public key ASBfrquH1MPI5aGa9lKPxv9opwiggox8AeQHrGMUiNy2mQo | |
To claim this, I am signing this object: |
This file contains 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
proxy: | |
image: tutum/haproxy | |
environment: | |
- BACKEND_PORT=4200 | |
ports: | |
- "4200:80" | |
links: | |
- crate | |
roles: | |
- global |
This file contains 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
# version 1 | |
require 'clockwork' | |
require './config/boot' | |
require './config/environment' | |
module DBBackedClockwork | |
extend Clockwork | |
# add a periodic job to update @@events |
This file contains 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
Non - VPC | |
sudo tcpdump -nieth0 -s0 port 53 | |
hostname -f | |
15:47:51.310998 IP 10.117.95.179.44198 > 172.16.0.23.53: 44142+ AAAA? ip-10-117-95-179.ec2.internal. (47) | |
15:47:51.311358 IP 172.16.0.23.53 > 10.117.95.179.44198: 44142 0/1/0 (108) | |
15:47:51.311785 IP 10.117.95.179.37773 > 172.16.0.23.53: 50187+ AAAA? ip-10-117-95-179. (34) | |
15:47:51.312091 IP 172.16.0.23.53 > 10.117.95.179.37773: 50187 NXDomain 0/1/0 (109) | |
15:47:51.312303 IP 10.117.95.179.57413 > 172.16.0.23.53: 3240+ A? ip-10-117-95-179.ec2.internal. (47) | |
15:47:51.312517 IP 172.16.0.23.53 > 10.117.95.179.57413: 3240 1/0/0 A 10.117.95.179 (63) |
This file contains 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
C:\Documents and Settings\Ian>vagrant plugin install vagrant-berkshelf | |
Installing the 'vagrant-berkshelf' plugin. This can take a few minutes... | |
C:/HashiCorp/Vagrant/embedded/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:556:in `rescue in block in build_extensions': ERROR: Failed to build gem native extension. (Gem::Installer::ExtensionBuildError) | |
C:/HashiCorp/Vagrant/embedded/bin/ruby.exe extconf.rb | |
creating Makefile | |
make | |
generating generator-i386-mingw32.def | |
compiling generator.c |
This file contains 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
{ | |
"error": { | |
"context": null, | |
"message": "The Response content must be a string or object implementing __toString(), "boolean" given.", | |
"code": 500, | |
"trace": [ | |
"0 /opt/dreamfactory/bootstrap/cache/compiled.php(15601): Symfony\\Component\\HttpFoundation\\Response->setContent(false)", | |
"1 /opt/dreamfactory/bootstrap/cache/compiled.php(15114): Illuminate\\Http\\Response->setContent(Array)", | |
"2 /opt/dreamfactory/bootstrap/cache/compiled.php(15123): Symfony\\Component\\HttpFoundation\\Response->__construct(Array, 200, Array)", | |
"3 /opt/dreamfactory/vendor/dreamfactory/df-core/src/Utility/ResponseFactory.php(155): Symfony\\Component\\HttpFoundation\\Response::create(Array, 200, Array)", |
This file contains 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
elasticsearch-data: | |
image: 'alpine' | |
command: '/bin/true' | |
volumes: | |
- '/data/elasticsearch:/usr/share/elasticsearch/data' | |
elasticsearch: | |
image: 'elasticsearch:1.5' | |
ports: | |
- '9200:9200' |
This file contains 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
auth: | |
image: 'ianneub/google-auth-proxy:latest' | |
command: '-upstream="http://kibana:5601/" -cookie-secret="asdfasdf" -http-address=0.0.0.0:80 -cookie-expire=8h0m0s' | |
environment: | |
- EMAIL_LIST=jdoe@domain.com\nasdf@domain.com | |
- OAUTH2_PROXY_CLIENT_ID=asdf-asdf.apps.googleusercontent.com | |
- OAUTH2_PROXY_CLIENT_SECRET=asdfasdf | |
- 'VIRTUAL_HOST=https://kibana.domain.com' | |
expose: | |
- '80' |
NewerOlder