Skip to content

Instantly share code, notes, and snippets.

@rafamaciel
Last active August 29, 2015 14:20
Show Gist options
  • Save rafamaciel/769d9392912bc818877c to your computer and use it in GitHub Desktop.
Save rafamaciel/769d9392912bc818877c to your computer and use it in GitHub Desktop.
Symfony configuration for openshift...
cd $OPENSHIFT_REPO_DIR
php $(find -name build_bootstrap.php)
<?php
$container->setParameter('database_host', getenv("OPENSHIFT_MYSQL_DB_HOST"));
$container->setParameter('database_port', getenv("OPENSHIFT_MYSQL_DB_PORT"));
$container->setParameter('database_name', getenv("OPENSHIFT_APP_NAME"));
$container->setParameter('database_user', getenv("OPENSHIFT_MYSQL_DB_USERNAME"));
$container->setParameter('database_password', getenv("OPENSHIFT_MYSQL_DB_PASSWORD"));
?>

Remove parameters.yml from .gitignore.

Import parameters.php on app/config/config.yml

imports:  
    - { resource: parameters.php }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment