git clone https://<username>@github.com/xxx/yyy.git
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 puppet apply --verbose | |
file { "/tmp/local": | |
content => "Test from puppet", | |
ensure => file | |
} |
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
rsync -rav -e 'ssh -i /Users/ashrith/.ssh/aws.pem' --exclude=".git/*" ${SOURCE_PATH} root@${HOST}:${PATH} | |
# Copying to remote server with out root user: | |
# for this command to work make sure the 'Defaults requiretty' is commented on the remote server in '/etc/sudoers' file | |
rsync -rav -e 'ssh -i /root/to/key' --rsync-path="sudo rsync" /path/to/copy/* rsyncuser@${HOST}:/dest/path/ |
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
# From a fresh install of squeeze | |
apt-get install ruby rubygems # Need ruby to use fpm | |
gem1.8 install fpm --no-ri --no-rdoc | |
apt-get install build-essential openssl libreadline6 libreadline6-dev zlib1g zlib1g-dev libssl-dev ncurses-dev libyaml-dev | |
wget ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p125.tar.gz | |
tar -zxvf ruby-1.9.3-p125.tar.gz | |
cd ruby-1.9.3-p125 | |
rm -rf /tmp/ruby193 |
Using the Job Control of bash to send the process into the background:
ctrl+z
to stop (pause) the program and get back to the shellbg
to run it in the backgrounddisown -h [job-spec]
where [job-spec] is the job number (like %1 for the first running job; find about your number with thejobs
command) so that the job isn't killed when the terminal closes
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
<?xml version="1.0" encoding="UTF-8"?> | |
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> | |
<modelVersion>4.0.0</modelVersion> | |
<parent> | |
<groupId>com.yahoo.ycsb</groupId> | |
<artifactId>root</artifactId> | |
<version>0.1.4</version> | |
</parent> | |
<artifactId>hbase-binding</artifactId> |
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
def test[T](t: T) = t match { | |
case _: Int => println("Got int" + t) | |
case _: String => println("Got string" + t) | |
case _ => println("I dont know what that is" + t) | |
} |
Config file:
cat > ~/.i2csshrc <<EOF
---
version: 2
clusters:
kafka_cluster:
login: ec2-user
hosts:
config file:
cat > aws_hosts <<EOF
clusters = kafka_cluster spark_cluster cass_cluster all
kafka_cluster = ec2-54-219-114-64.us-west-1.compute.amazonaws.com ec2-204-236-188-149.us-west-1.compute.amazonaws.com ec2-54-193-135-104.us-west-1.compute.amazonaws.com
spark_cluster = ec2-54-219-87-178.us-west-1.compute.amazonaws.com ec2-204-236-137-42.us-west-1.compute.amazonaws.com ec2-54-219-117-253.us-west-1.compute.amazonaws.com
cass_cluster = ec2-50-18-10-150.us-west-1.compute.amazonaws.com ec2-54-219-230-45.us-west-1.compute.amazonaws.com ec2-50-18-12-57.us-west-1.compute.amazonaws.com
all = ec2-54-219-114-64.us-west-1.compute.amazonaws.com ec2-204-236-188-149.us-west-1.compute.amazonaws.com ec2-54-193-135-104.us-west-1.compute.amazonaws.com ec2-54-219-87-178.us-west-1.compute.amazonaws.com ec2-204-236-137-42.us-west-1.compute.amazonaws.com ec2-54-219-117-253.us-west-1.compute.amazonaws.com ec2-50-18-10-150.us-west-1.compute.amazonaws.com ec2-54-219-230-45.us-west-1.compute.amazonaws.com ec2-50-18-12-57.us-
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
## Get a list of NIC names using `ifconfig -a` or `ip -a` | |
# | |
# vi /etc/sysconfig/network-scripts/ifcfg-en0xxxxxxx | |
NAME=en0xxxxxx | |
NM_CONTROLLED=no | |
ONBOOT=yes | |
HWADDR=A4:BA:DB:37:F1:04 | |
TYPE=Ethernet | |
BOOTPROTO=static |
OlderNewer