Last active
May 24, 2017 06:34
-
-
Save kolber/bf7d5b5556dbeb7962a5fd5692878e84 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#cloud-config | |
apt_update: true | |
packages: | |
- apache2 | |
- php | |
- libapache2-mod-php7.0 | |
- php-mbstring | |
- php7.0-curl | |
- php7.0-zip | |
- php7.0-json | |
- php7.0-xml | |
- php7.0-gd | |
- zip | |
- unzip | |
- wget | |
write_files: | |
- path: /etc/apache2/sites-available/000-default.conf | |
content: | | |
<VirtualHost *:80> | |
ServerAdmin [email protected] | |
DocumentRoot /var/www/html | |
ErrorLog ${APACHE_LOG_DIR}/error.log | |
CustomLog ${APACHE_LOG_DIR}/access.log combined | |
<Directory /var/www/html> | |
AllowOverride All | |
</Directory> | |
</VirtualHost> | |
- path: /var/www/html/index.php | |
content: | | |
<?php phpinfo(); ?> | |
runcmd: | |
- a2enmod rewrite | |
- sed -i -e "s/index.html index.cgi index.pl index.php/index.php index.html index.cgi index.pl/" /etc/apache2/mods-enabled/dir.conf | |
- service apache2 restart |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment