Skip to content

Instantly share code, notes, and snippets.

@djw8605
Created September 13, 2012 04:03
Show Gist options
  • Save djw8605/3711767 to your computer and use it in GitHub Desktop.
Save djw8605/3711767 to your computer and use it in GitHub Desktop.
htpc start script
#!/bin/sh
# Arguments
# 1 - Glidein configuration file
# 2 - Entry point (do we care?)
glidein_config=$1
entry_point=$2
condor_vars_file=`grep -i "^CONDOR_VARS_FILE " $glidein_config | awk '{print $2}'`
add_config_line_source=`grep '^ADD_CONFIG_LINE_SOURCE ' $glidein_config | awk '{print $2}'`
source $add_config_line_source
#SLOT_TYPE_1=100%
#SLOT_TYPE_1_PARTITIONABLE=TRUE
#NUM_SLOTS_TYPE_1=1
add_config_line SLOT_TYPE_1 "cpu=8,mem=16000"
add_condor_vars_line SLOT_TYPE_1 "C" "-" "SLOT_TYPE_1" "Y" "Y" "+"
add_config_line SLOT_TYPE_1_PARTITIONABLE "TRUE"
add_condor_vars_line SLOT_TYPE_1_PARTITIONABLE "C" "-" "SLOT_TYPE_1_PARTITIONABLE" "Y" "Y" "+"
add_config_line NUM_SLOT_TYPE_1 "1"
add_condor_vars_line NUM_SLOT_TYPE_1 "C" "-" "NUM_SLOT_TYPE_1" "Y" "Y" "+"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment