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
sudo apt-get install golang | |
sudo apt-get install libpulse-dev | |
go install github.com/nonoo/kappanhang@latest | |
pactl set-default-sink kappanhang-IC-705.2 | |
pactl set-default-source kappanhang-IC-705 |
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
protocol AudioStreamingDelegate { | |
func connectedDevicesChanged(manager: MultipeerHandler, connectedDevices: [String]) | |
} | |
class MultipeerHandler: NSObject { | |
private let peerType = "stream-audio" | |
private var peerId: MCPeerID! | |
private var serviceAdvertiser: MCNearbyServiceAdvertiser? | |
private var serviceBrowser: MCNearbyServiceBrowser? |
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
worker_processes 1; | |
events { | |
worker_connections 1024; | |
accept_mutex off; | |
use epoll; | |
} | |
http { | |
passenger_root /usr/local/lib/ruby/gems/1.9.1/gems/passenger-3.0.11; |
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
openssl req -new -nodes -keyout server.key -out server.csr |
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
/etc/apache2/ssl$ sudo openssl genrsa -out domain.key 2048 | |
sudo openssl req -new -key domain.key -out domain.csr |
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
cap deprec:users:passwd HOSTS=root@ | |
cap deprec:users:add HOSTS=root@ | |
cap deprec:ssh:config HOSTS= | |
ssh-keygen -t rsa | |
cap deprec:rack:install_stack | |
cap deprec:mysql:install | |
cap deprec:app:install |
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
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
. ~/.bashrc | |
mkdir ~/local | |
mkdir ~/node-install | |
cd ~/node-install | |
curl http://nodejs.org/dist/node-v0.4.11.tar.gz | tar xz --strip-components=1 | |
./configure --prefix=~/local | |
make install # ok, fine, this step probably takes more than 30 seconds... | |
curl http://npmjs.org/install.sh | sh |
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
namespace :db do | |
task :backup_name, :roles => :db, :only => { :primary => true } do | |
now = Time.now | |
run "mkdir -p db_backups" | |
backup_time = [now.year,now.month,now.day,now.hour,now.min,now.sec].join('-') | |
set :backup_file, "db_backups/#{application}-snapshot-#{backup_time}.sql" | |
end | |
desc 'Load remote production database into local development environment' | |
task :clone_to_local, :roles => :db, :only => { :primary => true } do |