-
Install any of the Mongo add-ons available at http://addons.heroku.com
-
Vendor the Mongo driver with your application. You can download it here:
https://github.com/wuputah/heroku-libraries/raw/master/php/mongo/mongo.so
Add it to a folder like "ext".
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
<?php | |
namespace Core\Controller; | |
class Action extends \Zend_Controller_Action | |
{ | |
/** | |
* EntityManager retornado | |
* @var \Doctrine\ORM\EntityManager | |
*/ | |
protected $em; |
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
<?php | |
/** | |
* Classe abstrata para funcionalidade de CRUD | |
* @author Daniel Lima <[email protected]> | |
* @example | |
* <code> | |
* <?php | |
* Module_Foo_Controller extexds Cilens_Controller_Crud | |
* { | |
* protected $_modelName = 'Foo'; |
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
<?php | |
/** | |
* Uso ser service class sem service locator | |
*/ | |
class CategoriaProdutoController extends Controller | |
{ | |
public function excluirAction() | |
{ | |
$id = $this->_getParam('id'); | |
$service = new CategoriaProdutoService; |
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
<?php | |
/* | |
* Workshop Doctrine 2 + ZF1 | |
* | |
*/ | |
namespace Application\Entity; | |
/** | |
* Usuario | |
* @author Administrator | |
*/ |
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
<?php | |
namespace Application\Entity; | |
use Doctrine\ORM\Mapping as ORM, | |
Doctrine\Common\Collections\ArrayCollection; | |
/** | |
* User | |
* @ORM\Entity | |
* @author Administrator |
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
[production] | |
; -------------------------- | |
; PHP Specific Configuration | |
; -------------------------- | |
phpSettings.display_startup_errors = 0 | |
phpSettings.display_errors = 0 | |
includePaths.library = APPLICATION_PATH "/../library" |
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
# First install requirements for BREW | |
# http://mxcl.github.com/homebrew/ | |
# https://github.com/mxcl/homebrew/wiki/installation | |
# Requirements | |
# - An Intel CPU 2 | |
# - OS X 10.5 or higher | |
# - Command Line Tools for Xcode (https://developer.apple.com/downloads) | |
# or Xcode with X11 (http://itunes.apple.com/us/app/xcode/id448457090) | |
# - Java Developer Update (https://connect.apple.com/) |
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
#!/bin/sh | |
# | |
# Script to prepare and restore full and incremental backups created with innobackupex-runner. | |
# | |
# This script is provided as-is; no liability can be accepted for use. | |
# | |
INNOBACKUPEX=innobackupex-1.5.1 | |
INNOBACKUPEXFULL=/usr/bin/$INNOBACKUPEX | |
TMPFILE="/tmp/innobackupex-restore.$$.tmp" |
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
# Ativar o modulo "mod_vhost_alias" do apache: sudo a2enmod vhost_alias | |
# Instalar o dnsmask: sudo apt-get install dnsmasq | |
# Adicionando ao final do arquivo "/etc/dnsmasq.conf" as seguintes linhas: | |
# listen-address=127.0.0.1 | |
# address=/.dev/127.0.0.1 | |
# | |
# Crie o arquivo de configuração do apache adcionandoas linhas a baixo | |
<VirtualHost *:80> | |
ServerAdmin webmaster@localhost |
OlderNewer