Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Multiple deployment environments (production/staging/etc) and Facebook Apps

I'm looking for a "best practice" kind of answer with regard to Facebook Apps and staging/production environment. Instinctively, I've provided each environment with its own Facebook App, complete with its own ID and secret. It appears (here, here and through extensive Googling) that it's simply not possible to share OG configuration across apps, so I've been copying application settings across environments (icon, requested permissions and texts, etc). It's been a pain and ugly, but I've lived with it.

Alas, with the introduction of opengraph actions, this isn't funny anymore - much more to copy and everything has to go through the approval process. Is there no better way to do this? A coworker suggested we simply share the same app across all environments, but I'm apprehensive about that - it means we'll have to share production secrets with the staging environment (I'm not even talking about localhost development environments), and that we'll need to route Facebook traffic to the correct environment somehow (because one Facebook app means one Page Tab URL).

There has to be a better way... no?

like image 925
Yaniv Aknin Avatar asked Feb 02 '23 06:02

Yaniv Aknin


1 Answers

I see there's a feature called "Test Apps" now that seems to fit the bill: https://developers.facebook.com/docs/apps/test-apps/

Test Apps are like regular apps in that they have their own App ID and independent settings, but they offer a number of advantages for use during pre-production: ... When creating test apps - the settings are copied from your production app so its simple to spinup new apps which mirror your production app's settings

It's working for me so far.

like image 61
brooks Avatar answered May 19 '23 22:05

brooks