2013-09-24 68 views
3

我正在使用此Laravel流浪:https://github.com/bryannielsen/Laravel4-Vagrant,我想添加PHPUNIT和一些其他PEAR包。流浪傀儡供應 - 梨包

我加在體現這一行/ phpbase.pp

include pearpackages 

我創造了這個文件木偶/模塊/ pearpackages /艙單/ init.pp:

class pearpackages { 
exec {"pear upgrade": 
    command => "/usr/bin/pear upgrade", 
    require => Package['php-pear'], 
    returns => [ 0, '', ' '] 
} 

# set channels to auto discover 
exec { "pear auto_discover" : 
    command => "/usr/bin/pear config-set auto_discover 1", 
    require => [Package['php-pear']] 
} 

exec { "pear update-channels" : 
    command => "/usr/bin/pear update-channels", 
    require => [Package['php-pear']] 
} 

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 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.phpqatools.org/PHP_CodeBrowser", 
    creates => '/usr/bin/phpcb', 
    require => Exec['pear update-channels'] 
} 
} 

後,我做一個無業遊民條款

似乎所有的配置,但是當我去本地主機:8888頁面始終加載,而不是顯示我的內容。

我不知道我在做什麼不好,但我需要你的幫助,請,系統配置是不是我的專業

+0

如果它的直接安裝有你嘗試去localhost:8888/public,因爲這是視覺文件保存的地方? –

回答

0

我找到了解決方案。 在某些版本中與Vagrant和VirtualBox有一些不兼容的地方。我不知道這個問題是否適用於嘉賓顧客。

隨着vagrant 1.6.2和VirtualBox 4.3.12正常工作。

0

您是否嘗試過使用PuPHPet生成您的木偶體現?您可以在語言部分輸入PEAR模塊。