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
xxx | |
sdfsdf | |
sd | |
fs | |
df | |
sdf | |
sd | |
fs | |
df |
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
<env:Envelope xmlns:lol0="http://ws.ottsso.singtel.com/clientauthws/" xmlns:lol1="http://ws.ottsso.singtel.com/commonottsso/" xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"> | |
<env:Header> | |
</env:Header> | |
<env:Body> | |
<lol0:checkSSOUserInfoParams> | |
<lol0:header> | |
<lol1:clientId>SMARTHOMERCS</lol1:clientId> | |
<lol1:timeStamp>2014-09-25T14:31:03+02:00</lol1:timeStamp> | |
<lol1:signature>123</lol1:signature> | |
</lol0:header> |
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
root@8751e3abfcea:/# ps ax | |
PID TTY STAT TIME COMMAND | |
1 ? Ss+ 0:00 /sleep 60 | |
11 ? Z 0:00 [sleep] <defunct> | |
12 ? Ss 0:00 bash | |
27 ? R+ 0:00 ps ax |
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
# generic build rule | |
docker/build/%: docker/recipes/%/Dockerfile .dockerignore | |
@echo | |
@echo | |
@echo =================================== Building $@ | |
@echo | |
@echo | |
docker build --rm -t $* -f "$<" . | |
docker inspect --format="{{.Id}}" $* > $@ | |
@echo |
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
DOCKER="`which docker`" | |
function docker() | |
{ | |
if [ -n "$1" ]; then | |
local cmd="$1"; shift | |
if which "docker-$cmd" > /dev/null; then | |
"docker-$cmd" "$@" | |
else | |
"$DOCKER" "$cmd" "$@" |
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
#!/bin/bash | |
# cleanup all stopped containers | |
# except for those that have 'data' in the name | |
echo Removing all stopped non-data containers | |
docker ps --filter "status=exited" \ | |
| grep -v data \ | |
| grep -v ^CONTAINER \ | |
| awk '{print $1}' \ | |
| xargs docker rm |
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
#vim: ruby | |
# | |
# This script will import all your Mephisto comments into Disqus (http:/disqus.com) | |
# parts of it came from http://www.locomotivation.com/blog/2008/12/01/disqus-sinatra-importer.html | |
# but instead of a blog-engine independent sinatra app we needed a mephisto-specific script that | |
# will just do the job :) | |
unless defined?(RAILS_ROOT) | |
puts "This is a Rails 'runner' script. Please run './script/runner path/to/disqus_import' inside your Mephisto directory" | |
exit |
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
if ($mystat{'Created_tmp_tables'} > 0) { | |
if ($mycalc{'pct_temp_disk'} > 25 && $mycalc{'max_tmp_table_size'} < 256*1024*1024) { | |
badprint "Temporary tables created on disk: $mycalc{'pct_temp_disk'}% (".hr_num($mystat{'Created_tmp_disk_tables'})." on disk / ".hr_num($mystat{'Created_tmp_disk_tables'} + $mystat{'Created_tmp_tables'})." total)\n"; | |
push(@adjvars,"tmp_table_size (> ".hr_bytes_rnd($myvar{'tmp_table_size'}).")"); | |
push(@adjvars,"max_heap_table_size (> ".hr_bytes_rnd($myvar{'max_heap_table_size'}).")"); | |
push(@generalrec,"When making adjustments, make tmp_table_size/max_heap_table_size equal"); | |
push(@generalrec,"Reduce your SELECT DISTINCT queries without LIMIT clauses"); | |
} elsif ($mycalc{'pct_temp_disk'} > 25 && $mycalc{'max_tmp_table_size'} >= 256) { | |
badprint "Temporary tables created on disk: $mycalc{'pct_temp_disk'}% (".hr_num($mystat{'Created_tmp_disk_tables'})." on disk / ".hr_num($mystat{'Created_tmp_disk_tables'} + $mystat{'Created_tmp_tables'})." total)\n"; | |
push(@genera |
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
>> class Configuration | |
>> def self.files | |
>> @@files ||= Array.new | |
>> end | |
>> def self.inspect | |
>> @@files.inspect | |
>> end | |
>> end | |
=> nil | |
>> Configuration.files << 1 |
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
class AccountsController < ApplicationController | |
before_filter :require_no_user, :only => [:new, :create] | |
before_filter :require_user, :only => [:show, :edit, :update] | |
def new | |
@user = User.new | |
@page_title = "Create Account" | |
render :template => "users/new" | |
end | |
OlderNewer