Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 33 lines (26 sloc) 902 Bytes
BASE_CACHE_DIR=/vagrant/.cache/
for f in "apt/archives"; do
rm -rf ${BASE_CACHE_DIR}$f; #remove symlink
rm -rf /var/cache/$f; #remove directory and contents if it exists
mkdir -p ${BASE_CACHE_DIR}$f;
ln -sf ${BASE_CACHE_DIR}$f /var/cache/$f;
done;
sed -i -e "s/us./za./g" /etc/apt/sources.list # Use the ZA mirror for software
apt-get update
export DEBIAN_FRONTEND=noninteractive
apt-get -q -y install apache2
echo "
<VirtualHost *:80>
SetEnv APPLICATION_ENV development
DocumentRoot /vagrant/
DirectoryIndex index.html
ServerSignature Off
ErrorLog /var/log/apache2/error.log
# Possible values include: debug, info, notice, warn, error, crit, alert, emerg.
LogLevel info
CustomLog /var/log/apache2/access.log combined
</VirtualHost>
" > /etc/apache2/sites-available/default
# Enable rewrite for apache
sudo a2enmod rewrite
service apache2 restart