User login

Sites-available configuration and symlinking best practices

beats by goose is in D5.1 so Agaric needs to get it to point to a directory specifically so the default can be made 5.2

This is the model it's currently following, below, for the general redirection:

But the one working to send Agaric to the drupal 5.2 directory isn't using NameVirtualHost, so I'm getting rid of it. I'm also putting in the options follow symlinks etc directory four line set.

And of course I add in the ServerName and ServerAlias lines for djgoose.net etc.

NameVirtualHost *:80
<VirtualHost *:80>
    ServerAdmin webmaster@example.com

    DocumentRoot /var/www/drupal-5-live
    <Directory />
        Options FollowSymLinks
        AllowOverride All
        Order allow,deny
        allow from all
    </Directory>

</VirtualHost>

NameVirtualHost *:8080
<VirtualHost *:8080>
    ServerAdmin webmaster@example.com

    DocumentRoot /var/www/drupal-5-2-test
    <Directory />
        Options FollowSymLinks
        AllowOverride None
    </Directory>
    <Directory /var/www/drupal-5-2-test>
        Options Indexes FollowSymLinks
        AllowOverride All
        Order allow,deny
        allow from all
    </Directory>

</VirtualHost>

10 second disaster.

A sites-available/beatsbygooose
Updated to revision 1499.

Cool, although the three o's in goose isn't a good idea.

ben@server:/etc/apache2$ sudo ln -s sites-available/beatsbygooose sites-enabled/beatsbygoose
ben@server:/etc/apache2$ sudo apache2ctl restart
apache2: Syntax error on line 672 of /etc/apache2/apache2.conf: Could not open configuration file /etc/apache2/sites-enabled/beatsbygoose: No such file or directory

And the quickly fix that:

ben@server:/etc/apache2$ sudo rm sites-enabled/beatsbygoose
ben@server:/etc/apache2$ sudo apache2ctl restart

Trying again, and checking this time. That command to make the symlink was was wrong.

lrwxrwxrwx 1 root root 29 2007-09-19 18:39 beatsbygoose -> sites-available/beatsbygooose

All the other symlink paths are preceded by ../sites-enabled

Resolution

Dan's absolutely right, we should make symlinks while in the directory where the symlink will be. Harder to screw up.

It's the Agaric way.

Comments

Post new comment

The content of this field is kept private and will not be shown publicly.
  • You may post code using <code>...</code> (generic) or <?php ... ?> (highlighted PHP) tags.
  • You can use Markdown syntax to format and style the text. Also see Markdown Extra for tables, footnotes, and more.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <img> <blockquote> <small> <h2> <h3> <h4> <h5> <h6> <sub> <sup> <p> <br> <strike> <table> <tr> <td> <thead> <th> <tbody> <tt> <output>
  • Lines and paragraphs break automatically.

More information about formatting options

By submitting this form, you accept the Mollom privacy policy.