These are the default files that I will usually start with when setting up a symfony2 project to use vagrant and puppet. I'm putting this readme file here for future updates.
Make sure the files that end in .sh
are executable.
# Gettting the state of the machine, ie Is it poweroff or running
Can be used in a script like so
//+------------------------------------------------------------------+ | |
//| LiveAlligator.mq4 | | |
//| Copyright © 2011, MetaQuotes Software Corp. | | |
//| http://www.mql4.com/ru/users/rustein | | |
//-------------------------------------------------------------------+ | |
// Trend Detection function | |
#define BULL 1 | |
#define BEAR 2 | |
// Input variables |
#!/bin/sh | |
baseurl=http://mygitlaburl | |
usermail=adminuser@mymailserver | |
userpass=adminpassword | |
repo_access=2 #0=denied 1=read 2=read&write | |
project_access=2 #0=deined 1=read 2=report 3=admin | |
# login | |
curl -s -I -c cookies.txt -d "utf8=✓&user[email]=$usermail&user[password]=$userpass&commit=Sign+in" $baseurl/users/sign_in |
<?php | |
use JMS\DiExtraBundle\Annotation as DI; | |
use Symfony\Component\HttpKernel\Event\FilterResponseEvent; | |
/** @DI\Service */ | |
class QSAListener | |
{ | |
private $blacklist; |
<?php | |
namespace Application\Sonata\UserBundle\Tests\Functional; | |
use IC\Bundle\Base\TestBundle\Test\WebTestCase; | |
class LoginTest extends WebTestCase | |
{ | |
/** | |
* {@inheritdoc} |
<?php | |
/* | |
* This file is part of the Symfony package. | |
* | |
* (c) Fabien Potencier <fabien@symfony.com> | |
* | |
* For the full copyright and license information, please view the LICENSE | |
* file that was distributed with this source code. | |
*/ |
# Disable NewRelic pinging | |
curl https://heroku.newrelic.com/accounts/xxxxx/applications/yyyyyyyy/ping_targets/disable -X POST -H "X-Api-Key: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" | |
heroku maintenance:on --app yourapp-staging | |
heroku pg:reset DATABASE --confirm yourapp-staging --app yourapp-staging | |
heroku pgbackups:restore DATABASE `heroku pgbackups:url --app yourapp-production` --app yourapp-staging --confirm yourapp-staging | |
git remote add heroku_yourapp-staging git@heroku.com:yourapp-staging.git | |
git push heroku_yourapp-staging $COMMIT_ID:master -f | |
heroku_run 'rake db:migrate' yourapp-staging | |
heroku restart --app yourapp-staging | |
heroku maintenance:off --app yourapp-staging |
<?php | |
namespace Standalone\Form; | |
use \Symfony\Component\HttpFoundation as SHttp; | |
use \Symfony\Component\Form as SForm; | |
use \Symfony\Component\DependencyInjection as SDI; | |
use \Symfony\Bridge as SBridge; | |
//Register all your autoload function here | |
//... |