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
apt-get -y update | |
apt-get -y install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev libcurl4-openssl-dev python-software-properties nodejs nginx-full redis-server postgresql postgresql-server-dev-9.4 mc wget imagemagick | |
adduser app | |
sudo su - app | |
ssh-keygen -t rsa -b 4096 | |
ssh -T git@github.com | |
git clone https://github.com/sstephenson/rbenv.git ~/.rbenv | |
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile | |
echo 'eval "$(rbenv init -)"' >> ~/.bash_profile | |
source .bash_profile |
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
c.Writer.Header().Set("Access-Control-Allow-Origin", "*") | |
c.Writer.Header().Set( | |
"Access-Control-Allow-Methods", | |
"POST, GET, OPTIONS, PUT, PATCH, DELETE") | |
c.Writer.Header().Set( | |
"Access-Control-Allow-Headers", | |
"Content-Type, Content-Length, Accept-Encoding, X-Original-Filename, X-Access-Token, Authorization") | |
if c.Request.Method == "OPTIONS" { | |
c.Abort(200) | |
return |
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
window && (window.__markets = [ | |
{ | |
name: 'markets.main.pass' | |
group_id: 1 | |
template: 'simple_options_list' | |
rows: [ | |
{ title: 'markets.main.pass_home', name: 'coeff_QS_1'} | |
{ title: 'markets.main.pass_away', name: 'coeff_QS_2'} | |
] | |
} |
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
www@Ubuntu-1304-raring-64-minimal:~/rush$ ruby daemons/collector.rb | |
I, [2014-03-27T18:54:03.821568 #7141] INFO -- : running server on 0.0.0.0:3097 | |
I, [2014-03-27T19:00:30.744193 #7141] INFO -- : new client [95.26.65.10:51732] connected | |
D, [2014-03-27T19:00:30.748926 #7141] DEBUG -- : > start/finish@Pong@$ | |
D, [2014-03-27T19:00:30.749030 #7141] DEBUG -- : < Rush@AckPong@Version2.1@$ | |
{ | |
:id => "start/finish", | |
:method => "Pong", | |
:values => [], | |
:message_number => 0 |
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
Я – Анастасия Волочкова, | |
Папа мой – Порфирий Волочков, | |
Жизнь моя сложилась бестолково: | |
Я влюбляюсь только в мудаков | |
Это – в смысле, я влюбляюсь телом. | |
Потому, что сердцем и душой | |
Я люблю своё по жизни дело, | |
В смысле, сцену и театр Большой |
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
upstream budo { | |
server 127.0.0.1:5000; | |
} | |
server { | |
listen 80; | |
server_name budo.ru; | |
root /home/www/budo.bugz.ru/current/public; | |
try_files $uri @budo; |
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
namespace :unicorn do | |
set :unicorn_pid, "#{app_path}/tmp/pids/unicorn.pid" | |
desc "Restart unicorn" | |
task :restart => :environment do | |
queue %{ | |
cd #{app_path} | |
test -s "#{unicorn_pid}" && kill -USR2 `cat "#{unicorn_pid}"` && echo "-----> Reload Ok" && exit 0 | |
bundle exec unicorn -c #{app_path}/config/unicorn.rb -E #{rails_env} -D && echo "-----> Start Ok" | |
} |
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
{ | |
status: 'error' | |
errors: [ | |
{ | |
id: 1 | |
priority: 1 | |
message: 'Первое сообщение' | |
cfs: [{ cid: 1, value: 123}, {cid: 2, value: 123}] | |
} | |
{ |
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
#include <unistd.h> | |
#include <stdio.h> | |
int main(int argc, char* argv[]) { | |
if (argc != 3) { | |
fprintf(stderr,"Use: hlink <src_dir> <target_dir>\n"); | |
return 1; | |
} | |
int ret = link(argv[1],argv[2]); | |
if (ret != 0) |
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
$parts: sprite-map("sprites/*.png", $layout: smart) | |
$parts_names: sprite_names($parts) | |
.sprite | |
+inline-block | |
background: $parts | |
background-repeat: no-repeat | |
@each $sprite in $parts_names | |
.sprite_#{$sprite} |
NewerOlder