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
#!/usr/bin/env python3 | |
import asyncio | |
import ssl | |
@asyncio.coroutine | |
async def echo_client(data, loop): | |
ssl_ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT) | |
ssl_ctx.options |= ssl.OP_NO_TLSv1 |
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
#![feature(unwind_attributes)] | |
use std::os::unix::thread::JoinHandleExt; | |
use libc::pthread_cancel; | |
struct DropGuard; | |
impl Drop for DropGuard { | |
fn drop(&mut self) { | |
println!("unwinding foo"); | |
} | |
} |
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 -l | |
APP_PATH=/home/ubuntu/www | |
GIT_WORK_TREE=$APP_PATH | |
export GIT_WORK_TREE | |
export PADRINO_ENV="production" | |
export RACK_ENV="production" | |
exit_with_error(){ | |
echo "[DEPLOY] !!!!!!!!!!!!!!!!!!!! Un error ah ocurrido !!!!!!!!!!!!!!!!!!!!!!!" | |
exit 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
#!/bin/bash | |
APP_NAME="your-app-name-goes-here" | |
APP_PATH=/home/deploy/${APP_NAME} | |
# Production environment | |
export RAILS_ENV="production" | |
# This loads RVM into a shell session. Uncomment if you're using RVM system wide. | |
# [[ -s "/usr/local/lib/rvm" ]] && . "/usr/local/lib/rvm" |