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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant::Config.run do |config| | |
config.vm.box = "precise32" | |
config.vm.box_url = "http://files.vagrantup.com/precise32.box" | |
# Assign this VM to a host-only network IP, allowing you to access it | |
# via the IP. Host-only networks can talk to the host machine as well as | |
# any other machines on the same network, but cannot be accessed (through this | |
# network interface) by any external networks. | |
config.vm.network :hostonly, "192.168.33.10" |
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
vagrant reload |
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
file {'testfile': | |
path => '/tmp/testfile', | |
ensure => present, | |
mode => 0640, | |
content => "I'm a test file.", | |
} |
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
include apache | |
$docroot = '/vagrant/www/pyrocms/' | |
$db_location = "/vagrant/db/pyrocms.sqlite" | |
# Apache setup | |
class {'apache::php': } | |
apache::vhost { 'local.pyrocms': | |
priority => '20', | |
port => '80', | |
docroot => $docroot, | |
configure_firewall => false, |
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
include php | |
php::module { ['xdebug', 'pgsql', 'curl', 'gd'] : | |
notify => [ Service['httpd'], ], | |
} | |
php::conf { [ 'pdo', 'pdo_pgsql']: | |
require => Package['php5-pgsql'], | |
notify => Service['httpd'], | |
} |
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
include postgresql | |
class {'postgresql::server': } | |
postgresql::db { 'pyrocms': | |
owner => 'pyrocms', | |
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
file { $docroot: | |
ensure => 'directory', | |
} | |
file { "${docroot}system/cms/config/config.php": | |
ensure => "present", | |
mode => "0666", | |
require => File[$docroot], | |
} | |
$writeable_dirs = ["${docroot}system/cms/cache/", "${docroot}system/cms/config/", "${docroot}addons/", "${docroot}assets/cache/", "${docroot}uploads/"] | |
file { $writeable_dirs: |
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
git clone --recursive git://github.com/pyrocms/devops-vagrant.git ~/vagrant/pyrocms | |
cd ~/vagrant/pyrocms | |
vagrant up |
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
https://github.com/rogeriopradoj/codeigniter-validation/commit/1e3300ebcfe6c233668a3b234d2554fe92854541#commitcomment-2316728 | |
@sputinyk: | |
Interessante, mas seria mais fácil fazer: | |
$_POST = $data; | |
E utilizar a classe nativa de validação do CI. Faz sentido o que disse? |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant::Config.run do |config| | |
# define box base | |
config.vm.box = "precise32" | |
# url para download automático da box se primeira utilização | |
config.vm.box_url = "http://files.vagrantup.com/precise32.box" | |
# define modo interface de rede e ip fixo |