Skip to content

Instantly share code, notes, and snippets.

View evancauwenberg's full-sized avatar

Evert Van Cauwenberg evancauwenberg

View GitHub Profile
dependencies[] = ctools
; Views Handlers
files[] = views/mymodule_handler_handlername.inc
# Slow query log
SET GLOBAL query_cache_type=OFF;
SET GLOBAL log_slow_queries = 1;
SET GLOBAL log_queries_not_using_indexes = 'ON';
SET GLOBAL long_query_time = 2;
FLUSH LOGS;
# Log all queries
SET GLOBAL query_cache_type=OFF;
SET global log_output = 'FILE';
<?php
/**
* Disable and uninstall a feature module.
*
* Note: see some edge cases where some exported components like content types
* need to be removed manually.
*/
function mymodule_update_7100() {
// Note that this does not take care of disabling modules that depend

I have managed to install this… and make it work. I implemented it for Facebook and Google, but you can extend it. My solution it is mostly as described in #116, with a bit of more code presented. The key aspects that lack in the #116 presentation (IMO) are:

  • the registration as service of your custom FOSUBUserProvider (with the necessary parameters)
  • set the service for oauth_user_provider in the security.yml with your custom created service

Here are the steps:

  1. Routing. In routing.yml I have added all the routes for both bundles.
  2. Configuration. I have set the config.yml mostly as it is presented in the HWIOAuthBundle.
  3. Security. I have set the security.yml mostly as it is presented in the HWIOAuthBundle (though my routes are using /login pattern, not /connect). Also, the oauth_user_provider is set for my custom service.
<?php
namespace Renoir\AggregationBundle;
/**
* Abstract client to use for each Client
*
* Example location: src/Renoir/AggregationBundle/AbstractClient.php
**/
dependencies[] = ctools
; Views Handlers
files[] = views/mymodule_handler_handlername.inc
<project name="My Project Name" default="build">
<target name="clean">
<delete dir="${basedir}/build" />
</target>
<target name="prepare">
<mkdir dir="${basedir}/build/logs" />
<mkdir dir="${basedir}/build/codebrowser" />
<mkdir dir="${basedir}/build/coverage" />
<mkdir dir="${basedir}/build/cpd" />
#!/bin/bash
DESC="Selenium Grid Server"
RUN_AS="selenium"
JAVA_BIN="/usr/bin/java"
SELENIUM_DIR="/opt/selenium"
PID_FILE="$SELENIUM_DIR/selenium-grid.pid"
JAR_FILE="$SELENIUM_DIR/selenium-server.jar"
LOG_DIR="/var/log/selenium"
<!--
This file is for Continuous Integration server
Please don't edit this file if you are not sure what you are doing.
For any change please consult it with appropriate person.
Author: Martin Malek <martin.malek@pagewiser.cz>
-->
<project name="project" default="" basedir=".">
<!-- Define for use with windows -->
<?php
abstract class AbstractRestController
{
/**
* @var \Symfony\Component\Form\FormFactoryInterface
*/
protected $formFactory;