Changeset 459


Ignore:
Timestamp:
Oct 24, 2012, 12:24:56 AM (8 years ago)
Author:
amain
Message:

bitten: allow contolling slaves from web interface

Location:
branches/contrib/bitten
Files:
14 added
5 deleted
1 edited
2 copied

Legend:

Unmodified
Added
Removed
  • branches/contrib/bitten/slaves/include/slaves.inc.sh

    r457 r459  
    1818# along with this program.  If not, see <http://www.gnu.org/licenses/>.
    1919
     20set -x
     21
    2022run=${1}
    2123ini=${2}
     24recipe=${3}
    2225
    2326if [ ! "${run}" = "run" ]
     
    3033fi
    3134
     35if [ -f ${recipe} ]
     36then
     37   # assume user supplied local recipy file
     38   shift
     39   mode=local
     40else
     41   unset recipe
     42   mode=remote
     43fi
     44
    3245function usage()
    3346{
    3447   cat <<EOF
    35 usage: $(basename $0) <slave.ini> [ slave-arg1, .. ]
     48usage: $(basename $0) <slave.ini> [ recipe.xml ] [ slave-arg1, .. ]
    3649
    3750Start bitten slave with <slave.ini> configuration.
     
    6073arch=${1/.*/}
    6174name=$(hostname -f)
    62 work=~/build/${target_architecture}/${target_system}/${target_profile}
    63 server="http://dev.debwrt.net"
     75work=~/build
     76server_or_recipe="${recipe:-http://dev.debwrt.net}"
    6477log=${work}/bitten.log
     78basedir='${platform}/${config}/${build}'
    6579
    6680mkdir -p ${work}
     
    7084
    7185slave name         : ${name}
    72 target architecture: ${target_architecture}
    73 target profile     : ${target_profile}
    74 target system      : ${target_system}
    7586ini                : ${ini}
    7687work               : ${work}
     88basedir            : ${basedir}
    7789log                : ${log}
     90mode               : ${mode}
    7891
    7992EOF
     
    8598             --config ${ini} \
    8699             --work-dir ${work} \
     100             --build-dir ${basedir} \
    87101             --log ${log} \
    88102             --name ${name} \
    89103             --exit-no-pending \
     104             --dump-reports \
    90105             $@ \
    91              ${server}
     106             ${server_or_recipe}
    92107
Note: See TracChangeset for help on using the changeset viewer.