Skip to content

Latest commit

 

History

History
46 lines (30 loc) · 1.26 KB

README.md

File metadata and controls

46 lines (30 loc) · 1.26 KB

Simple, Heroku-friendly Rails app configuration using ENV and a single YAML file

Figaro for Apollo

Apollo is a applicaiton configuration center. When we hanve many sub-portal and want to unified management all config/application.yml. This Gem result from the idea.

Getting Started

Add Figaro to your Gemfile and bundle install:

gem 'figaro', git: "https://github.com/feed-mob/feedmob-figaro", branch: 'master'

Using exclude development

It load apollo.yml to config apollo configuration center.

example:

APOLLO_CLUSTER: default
APOLLO_APP_ID: feedmob-XXX
APOLLO_HOST: http://localhost:8080
APOLLO_CUSTOM_CONFIG_FILE: ''

 stage:
  APOLLO_HOST: http://xxx.com:8080

 production:
  APOLLO_HOST: http://xxx.com:8080

If Apollo has configured, after this will overwrite local config/application.yml and config/sidekiq.yml

Tip

  • This Gem start when rails before configuration,
  • If you single start sidekiq, Please start rails server first.
  • Add prefix SKIP_APOLLO=true to the command If you want to run a command on stage/production environment without downloading apollo configurations

Using in development

Just see the doc from the official.