php /hosting/drush/drush.php --uri=http://aegir.example.com hosting-setup
A Drupal installation directory could not be found [error]
The command 'drush.php hosting-setup' could not be found.

I added aegir.example.com to /etc/hosts

i also wanted to do it on the localhost
php /hosting/drush/drush.php --uri=http://localhost/aegir hosting-setup
A Drupal installation directory could not be found [error]
The command 'drush.php hosting-setup' could not be found.

I wasn't sure how to setup config/vhost.d for localhost
do I do the following
config/vhost.d/localhost/aegir
or
config/vhost.d/aegir

Comments

Anonymous’s picture

Category: bug » support

You didn't run the command from inside the platform directory ie /var/aegir/hostmaster-0.4alphaX

You don't need to 'setup config/vhost.d for localhost', if you follow the INSTALL.txt and execute the install.sh script, this is all done automatically for you.

socialnicheguru’s picture

I am using MAMP.
I have my web serer root in a different place from /var/aegir.

Will this be a problem?

Anonymous’s picture

Nope, it doesn't matter so much *where* the platform is. It's just that you need to be *inside* the platform directory before you run the Drush command, as the Drush command expects the working directory to be within a valid Drupal installation. Otherwise it doesn't know how to bootstrap.

That's the meaning behind the error A Drupal installation directory could not be found.

In the install.php, the correct commands would've been given to you for copying and pasting:

su -s /bin/sh aegir
cd /path/to/your/platform/inside/your/MAMP/directory
php /var/aegir/drush/drush.php --uri=http://youraegir.site.com hosting-setup
adrian’s picture

Also, aegir can't be installed in a subdirectory. Each site on aegir needs it's own hostname, so you can't have http://localhost/aegir

You can have localhost be aegir and only aegir though, and then create additional host entries for each site you spawn.

adrian’s picture

Status: Active » Postponed (maintainer needs more info)

You cant install aegir in a subdirectory (ie: it _needs_ a host name.)

this is documented in the install.txt.

if there's anything else you need to know, please get back to us.

adrian’s picture

Status: Postponed (maintainer needs more info) » Closed (fixed)

closing,