Created
March 22, 2012 04:07
-
-
Save sime/2155788 to your computer and use it in GitHub Desktop.
Pagoda Boxfile for CakePHP
This file contains hidden or 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 | |
// Source: http://help.pagodabox.com/customer/portal/articles/174049-cakephp#setting-global-server-variables-in-database-php | |
define("DB_HOST", $_SERVER['DB1_HOST']); | |
define("DB_NAME", $_SERVER['DB1_NAME']); | |
define("DB_USER", $_SERVER['DB1_USER']); | |
define("DB_PASS", $_SERVER['DB1_PASS']); | |
define("DB_PORT", $_SERVER['DB1_PORT']); | |
class DATABASE_CONFIG { | |
public $default = array( | |
'datasource' => 'Database/Mysql', | |
'persistent' => false, | |
'host' => DB_HOST, | |
'login' => DB_USER, | |
'password' => DB_PASS, | |
'database' => DB_NAME, | |
'prefix' => '', | |
'port' => DB_PORT, | |
); | |
} |
This file contains hidden or 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
# vim: set ft=yaml expandtab tabstop=2 shiftwidth=2 softtabstop=2: | |
web1: | |
document_root: /app/webroot | |
shared_writable_dirs: | |
- app/tmp | |
- app/tmp/cache | |
- app/tmp/cache/models | |
- app/tmp/cache/persistent | |
- app/tmp/cache/views | |
- app/tmp/logs | |
- app/tmp/sessions | |
- app/tmp/tests | |
php_extensions: | |
- mcrypt | |
- mbstring | |
- pdo_mysql | |
- apc | |
after_build: | |
- "mv app/Config/database.php.pagoda app/Config/database.php" | |
before_deploy: | |
# https://github.com/CakeDC/migrations | |
- "app/Console/cake Migrations.migration all" | |
after_deploy: | |
- "rm -rf app/tmp/cache/models/*" | |
- "rm -rf app/tmp/cache/persistent/*" | |
- "rm -rf app/tmp/cache/views/*" | |
# Stop Content-Length header from being set, by default the value is incorrect | |
php_zlib_output_compression: On | |
db1: | |
type: mysql |
If you don't have the migrations plugin installed and the directory named 'migrations' (lowercase 'm') the deploy will likely fail.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
Thanks for this..
However, with the migrations i am getting Permission denied. Any ideas?