diff options
Diffstat (limited to 'share')
-rwxr-xr-x | share/hydra/whereis | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/share/hydra/whereis b/share/hydra/whereis index 6aff32d..687b280 100755 --- a/share/hydra/whereis +++ b/share/hydra/whereis @@ -50,11 +50,13 @@ if [ -e "$PUPPET/manifests/nodes/$LAYER.pp" ]; then fi # Is it a website? -if [ -e "$PUPPET/manifests/classes/websites.pp" ] && \ - grep -e "apache::site" "$PUPPET/manifests/classes/websites.pp" | grep -q "$LAYER" ; then - echo "Defined as a website on $PUPPET/manifests/classes/websites.pp:" +if [ -e "$PUPPET/modules/site_websites" ] && \ + grep -R -e "apache::site" "$PUPPET/modules/site_websites/manifests/" | grep -q "$LAYER" ; then + MANIFEST="$(cd $PUPPET && grep -R -e "apache::site" "modules/site_websites/manifests/" | grep "$LAYER" | cut -d : -f 1)" + + echo "Defined as a website on $MANIFEST:" echo "" - sed -n -e "/apache::site { \"$LAYER\":/,/ }/ p" $PUPPET/manifests/classes/websites.pp + sed -n -e "/apache::site { \"$LAYER\":/,/ }/ p" $PUPPET/$MANIFEST fi # DNS config |