aboutsummaryrefslogtreecommitdiff
path: root/control/setup-control-node-via-ssh
blob: 1cac59d2297da702a3d8e46c8741de0354618d91 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/sh
###############################################################################
# Copyright (c) 2011 Linaro
# All rights reserved. This program and the accompanying materials
# are made available under the terms of the Eclipse Public License v1.0
# which accompanies this distribution, and is available at
# http://www.eclipse.org/legal/epl-v10.html
###############################################################################
#
# This script installs cloud-buildd on a completely pristine host via SSH

set -xe

HOST=$1
BRANCH=$2
CRED=ubuntu@$HOST
echo "Installing cloud-buildd on: $HOST"

ssh -A $CRED <<EOF
    set -xe
    sudo apt-get update -qq
    sudo apt-get install -qq -y bzr
    rm -rf linaro-android-build-tools
    bzr clone $BRANCH linaro-android-build-tools
    cd linaro-android-build-tools/control/
    ./setup-control-node $HOST
EOF