Permalink
Browse files

Initial commit

  • Loading branch information...
0 parents commit 54d74c475d3e10d653d81029ed06842fadba48bc @ricbra committed Mar 6, 2012
Showing with 65 additions and 0 deletions.
  1. +1 −0 .gitignore
  2. +1 −0 .vagrant
  3. +15 −0 Vagrantfile
  4. +5 −0 manifests/site.pp
  5. +10 −0 modules/php54/files/sources.list
  6. +22 −0 modules/php54/manifests/init.pp
  7. +11 −0 www/index.php
@@ -0,0 +1 @@
+.project
@@ -0,0 +1 @@
+{"active":{"default":"e1dc40f1-89d6-454d-a813-bddd56f7574a"}}
@@ -0,0 +1,15 @@
+Vagrant::Config.run do |config|
+ config.vm.box = "squeeze32"
+ config.vm.host_name = "php54"
+ # taken from vagrantbox.es
+ config.vm.box_url = "http://mathie-vagrant-boxes.s3.amazonaws.com/debian_squeeze_32.box"
+ config.vm.boot_mode = :gui
+ config.vm.network :hostonly, "33.33.33.10"
+ config.vm.share_folder "www", "/var/www", "./www"
+
+ config.vm.provision :puppet do |puppet|
+ puppet.manifests_path = "manifests"
+ puppet.module_path = "modules"
+ puppet.manifest_file = "site.pp"
+ end
+end
@@ -0,0 +1,5 @@
+group { "puppet":
+ ensure => present
+}
+
+include php54
@@ -0,0 +1,10 @@
+deb http://mirror.bytemark.co.uk/debian/ squeeze main
+deb-src http://mirror.bytemark.co.uk/debian/ squeeze main
+
+deb http://security.debian.org/ squeeze/updates main
+deb-src http://security.debian.org/ squeeze/updates main
+
+deb http://mirror.bytemark.co.uk/debian/ squeeze-updates main
+deb-src http://mirror.bytemark.co.uk/debian/ squeeze-updates main
+
+deb http://packages.dotdeb.org/ squeeze-php54 all
@@ -0,0 +1,22 @@
+class php54 {
+ file { "/etc/apt/sources.list":
+ ensure => file,
+ owner => root,
+ group => root,
+ source => "puppet:///modules/php54/sources.list",
+ }
+ exec { "import-gpg":
+ command => "/usr/bin/wget -q http://www.dotdeb.org/dotdeb.gpg -O -| /usr/bin/apt-key add -"
+ }
+
+ exec { "/usr/bin/apt-get update":
+ require => [File["/etc/apt/sources.list"], Exec["import-gpg"]],
+ }
+
+ package { [
+ "php5"
+ ] :
+ ensure => latest,
+ require => Exec["/usr/bin/apt-get update"]
+ }
+}
@@ -0,0 +1,11 @@
+<?php
+
+$array = [];
+
+trait Foo {
+ public function bar() {
+ echo "Hello world";
+ }
+}
+
+echo "test";

0 comments on commit 54d74c4

Please sign in to comment.