Skip to content

Instantly share code, notes, and snippets.

View zeopix's full-sized avatar

Ivan Guillen zeopix

View GitHub Profile
@zeopix
zeopix / wp-rocket_inc_Engine_Preload_Subscriber.php
Created September 7, 2023 08:39
[WP Rocket] Clear cache once for certain hooks.
'after_rocket_clean_domain_outside_the_loop' => 'clean_full_cache',

#Meteor and Self-hosted Infrastructure

Meteor is an eye-opening JavaScript framework that runs on both the client and the server, giving developers a revolutionary take on software engineering. If you are not familiar with Meteor, I urge you to visit their website.

##An overview

In this brief gist, I am going to discuss the process of setting up a server (in my case, a VPS) to host Meteor applications.

My experience with Meteor has been brief, however it has not taken much demonstration for me to realise the significance of this stellar framework. Let's jump right in!

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.
@zeopix
zeopix / Project-Build-Settings
Created September 17, 2012 13:45
My Build Settings
solved
<?php
namespace Jet\ShopBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Validator\Constraints as Assert;
/**
* Jet\ShopBundle\Entity\Product
*
@zeopix
zeopix / LICENSE.txt
Created October 14, 2011 11:54 — forked from fgnass/LICENSE.txt
The Mandelbro™
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 Felix Gnass <http://twitter.com/fgnass>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE