summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
Diffstat (limited to 'share')
-rwxr-xr-xshare/hydra/nodes19
1 files changed, 2 insertions, 17 deletions
diff --git a/share/hydra/nodes b/share/hydra/nodes
index 4ddf916..e2a318d 100755
--- a/share/hydra/nodes
+++ b/share/hydra/nodes
@@ -20,31 +20,16 @@
function hydra_node_files {
if [ -d "$PUPPET/hiera/node/" ]; then
FILES="$PUPPET/hiera/node/*"
- elif [ -d "$PUPPET/manifests/nodes/" ]; then
- FILES="$PUPPET/manifests/nodes/*"
- else
- FILES="`find $PUPPET -name 'nodes.pp'`"
fi
}
-# Get using the filename
-function hydra_node_names {
+# Return node names
+function hydra_nodes {
for file in $FILES; do
basename $file .yaml
done
}
-# Get all lines matching a node definition
-function hydra_node_lines {
- # See http://www.mail-archive.com/puppet-users@googlegroups.com/msg01615.html
- grep ^node $FILES | sed -e 's/^node //' | awk -F, '{for(i=1;i<=NF;i++) {print $i}}'
-}
-
-# Default node retrieval method
-function hydra_nodes {
- hydra_node_names
-}
-
# Load
source $APP_BASE/lib/hydra/functions || exit 1
hydra_config_load