Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:boombatower
drupal-vhosts
drupal-vhosts
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File drupal-vhosts of Package drupal-vhosts
#!/bin/bash if [ $# -eq 0 ] then echo 'Usage: drupal-vhosts DRUPAL_ROOT_DIRECTORY' exit fi drupal_root=$1 vhost=/etc/apache2/vhosts.d/drupal.conf if [ -d "$drupal_root" ] then # clear vhost file echo "# Auto-generated by drupal-vhosts package" > $vhost # check which Drupal version exist and generate vhost config for them for version in 5 6 7 8; do directory="$drupal_root/drupal-$version" if [ -d "$directory" ] then echo "Found Drupal $version." echo "# Drupal $version <VirtualHost *> ServerName d${version}x.loc ServerAlias *.d${version}x.loc ServerAdmin root@site.loc DocumentRoot $directory <Directory $directory> AllowOverride FileInfo AuthConfig Limit Indexes Options=All,MultiViews Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec Order allow,deny Allow from all </Directory> </VirtualHost> " >> $vhost fi done else echo "'$drupal_root' is not a valid directory." fi
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor