-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
starting 3.0 branch, vagrant works, not integrated into tests yet
- Loading branch information
1 parent
9577cc8
commit 681ed7b
Showing
1,178 changed files
with
389,754 additions
and
14 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
.idea/ | ||
.vagrant/ | ||
*.pid* | ||
*.jar* | ||
*.zip* | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
Vagrant.configure("2") do |config| | ||
config.vm.box = "trusty64" | ||
config.vm.box_url = "http://cloud-images.ubuntu.com/vagrant/trusty/current/trusty-server-cloudimg-amd64-vagrant-disk1.box" | ||
|
||
config.vm.network :forwarded_port, guest: 80, host: 8080 | ||
|
||
config.vm.provision :puppet do |puppet| | ||
puppet.manifests_path = "puppet/manifests" | ||
puppet.module_path = "puppet/modules" | ||
puppet.manifest_file = "init.pp" | ||
puppet.options="--verbose --debug" | ||
end | ||
|
||
# Fix for slow external network connections | ||
config.vm.provider :virtualbox do |vb| | ||
vb.customize ['modifyvm', :id, '--natdnshostresolver1', 'on'] | ||
vb.customize ['modifyvm', :id, '--natdnsproxy1', 'on'] | ||
end | ||
end |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
User vagrant | ||
Group vagrant |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
LoadModule rewrite_module /usr/lib/apache2/modules/mod_rewrite.so |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
<VirtualHost *:80> | ||
ServerAdmin webmaster@localhost | ||
|
||
DocumentRoot /vagrant/wordpress | ||
|
||
# correct caching issue where edited images do not refresh http://www.mabishu.com/blog/2013/05/07/solving-caching-issues-with-vagrant-on-vboxsf/ | ||
EnableSendfile off | ||
|
||
# phpmyadmin routing | ||
Alias /phpmyadmin /usr/share/phpmyadmin | ||
|
||
<Directory /vagrant/wordpress> | ||
Options Indexes FollowSymLinks | ||
AllowOverride None | ||
Require all granted | ||
RewriteEngine On | ||
RewriteBase / | ||
RewriteRule ^index\.php$ - [L] | ||
RewriteCond %{REQUEST_FILENAME} !-f | ||
RewriteCond %{REQUEST_FILENAME} !-d | ||
RewriteRule . /index.php [L] | ||
</Directory> | ||
|
||
ErrorLog ${APACHE_LOG_DIR}/vagrantpress.error.log | ||
|
||
# Possible values include: debug, info, notice, warn, error, crit, | ||
# alert, emerg. | ||
LogLevel warn | ||
|
||
CustomLog ${APACHE_LOG_DIR}/vagrantpress.access.log combined | ||
</VirtualHost> |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
exec { 'apt_update': | ||
command => 'apt-get update', | ||
path => '/usr/bin' | ||
} | ||
|
||
class { 'git::install': } | ||
class { 'subversion::install': } | ||
class { 'apache2::install': } | ||
class { 'php5::install': } | ||
class { 'mysql::install': } | ||
class { 'wordpress::install': } | ||
class { 'phpmyadmin::install': } | ||
class { 'phpqa::install': } |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
# Install Apache | ||
|
||
class apache2::install { | ||
|
||
File { | ||
ensure => file, | ||
owner => 'root', | ||
group => 'root', | ||
mode => '0644', | ||
require => Package['apache2'], | ||
notify => Service['apache2'], | ||
} | ||
|
||
package { 'apache2': | ||
ensure => present, | ||
}-> | ||
|
||
service { 'apache2': | ||
ensure => running, | ||
} | ||
|
||
# the httpd.conf change the user/group that apache uses to run its process | ||
file { '/etc/apache2/conf-available/user.conf': | ||
source => '/vagrant/files/etc/apache2/httpd.conf', | ||
} | ||
|
||
file { '/etc/apache2/conf-enabled/user.conf': | ||
ensure => link, | ||
target => '/etc/apache2/conf-available/user.conf', | ||
} | ||
|
||
file { '/etc/apache2/sites-available/default.conf': | ||
source => '/vagrant/files/etc/apache2/sites-available/default.conf', | ||
} | ||
|
||
file { '/etc/apache2/mods-available/rewrite.load': | ||
source => '/vagrant/files/etc/apache2/mods-available/rewrite.load', | ||
} | ||
|
||
file { '/etc/apache2/sites-enabled/000-default.conf': | ||
ensure => link, | ||
target => '/etc/apache2/sites-available/default.conf', | ||
} | ||
|
||
file { '/etc/apache2/mods-enabled/rewrite.load': | ||
ensure => link, | ||
target => '/etc/apache2/mods-available/rewrite.load', | ||
} | ||
|
||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Install git | ||
|
||
class git::install { | ||
|
||
package{'git': | ||
ensure=>present, | ||
} | ||
|
||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#Install MySQL | ||
|
||
class mysql::install { | ||
|
||
$password = 'vagrant' | ||
|
||
package { [ | ||
'mysql-client', | ||
'mysql-server', | ||
]: | ||
ensure => installed, | ||
} | ||
|
||
exec { 'Set MySQL server\'s root password': | ||
subscribe => [ | ||
Package['mysql-server'], | ||
Package['mysql-client'], | ||
], | ||
refreshonly => true, | ||
unless => "mysqladmin -uroot -p${password} status", | ||
path => '/bin:/usr/bin', | ||
command => "mysqladmin -uroot password ${password}", | ||
} | ||
|
||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Install PHP | ||
|
||
class php5::install { | ||
|
||
package { [ | ||
'php5', | ||
'php5-mysql', | ||
'php5-curl', | ||
'php5-gd', | ||
'php5-fpm', | ||
'libapache2-mod-php5', | ||
'php5-dev', | ||
'php5-xdebug', | ||
'php-pear', | ||
]: | ||
ensure => present, | ||
} | ||
|
||
# upgrade pear | ||
exec {"pear upgrade": | ||
command => "/usr/bin/pear upgrade", | ||
require => Package['php-pear'], | ||
} | ||
|
||
# set channels to auto discover | ||
exec { "pear auto_discover" : | ||
command => "/usr/bin/pear config-set auto_discover 1", | ||
require => [Package['php-pear']] | ||
} | ||
|
||
# update channels | ||
exec { "pear update-channels" : | ||
command => "/usr/bin/pear update-channels", | ||
require => [Package['php-pear']] | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# Install phpMyAdmin | ||
|
||
class phpmyadmin::install { | ||
|
||
package { 'phpmyadmin': | ||
ensure => present, | ||
} | ||
|
||
file { '/etc/apache2/sites-enabled/001-phpmyadmin': | ||
ensure => link, | ||
target => '/etc/phpmyadmin/apache.conf', | ||
require => Package['apache2'], | ||
notify => Service['apache2'], | ||
} | ||
|
||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
#Install the PHP Quality Assurance Toolchain | ||
|
||
class phpqa::install{ | ||
exec {"pear install phpunit": | ||
command => "/usr/bin/pear install --alldeps pear.phpunit.de/PHPUnit", | ||
creates => '/usr/bin/phpunit', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install phploc | ||
exec {"pear install phploc": | ||
command => "/usr/bin/pear install --alldeps pear.phpunit.de/phploc", | ||
creates => '/usr/bin/phploc', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install phpcpd | ||
exec {"pear install phpcpd": | ||
command => "/usr/bin/pear install --alldeps pear.phpunit.de/phpcpd", | ||
creates => '/usr/bin/phpcpd', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install phpdcd | ||
exec {"pear install phpdcd": | ||
command => "/usr/bin/pear install --alldeps pear.phpunit.de/phpdcd-beta", | ||
creates => '/usr/bin/phpdcd', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install phpcs | ||
exec {"pear install phpcs": | ||
command => "/usr/bin/pear install --alldeps PHP_CodeSniffer", | ||
creates => '/usr/bin/phpcs', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install WordPress Coding Standard sniffs | ||
# http:////github.com/WordPress-Coding-Standards/WordPress-Coding-Standards | ||
exec { "Install WP phpcs sniffs": | ||
command => "/usr/bin/git clone git://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards.git $(pear config-get php_dir)/PHP/CodeSniffer/Standards/WordPress", | ||
unless => "/usr/bin/test -d $(pear config-get php_dir)/PHP/CodeSniffer/Standards/WordPress", | ||
require => Exec['pear update-channels', 'pear install phpcs'] | ||
} | ||
|
||
# install phpdepend | ||
exec {"pear install pdepend": | ||
command => "/usr/bin/pear install --alldeps pear.pdepend.org/PHP_Depend-beta", | ||
creates => '/usr/bin/pdepend', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install phpmd | ||
exec {"pear install phpmd": | ||
command => "/usr/bin/pear install --alldeps pear.phpmd.org/PHP_PMD", | ||
creates => '/usr/bin/phpmd', | ||
require => Exec['pear update-channels'] | ||
} | ||
|
||
# install PHP_CodeBrowser | ||
exec {"pear install PHP_CodeBrowser": | ||
command => "/usr/bin/pear install --alldeps pear.phpunit.de/PHP_CodeBrowser", | ||
creates => '/usr/bin/phpcb', | ||
require => Exec['pear update-channels'] | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
# Install subversion | ||
|
||
class subversion::install { | ||
package { | ||
'subversion': | ||
ensure => present, | ||
} | ||
} |
Oops, something went wrong.