No commit activity in last 3 years
No release in over 3 years
Generate DATABASE_URL and such
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
 Dependencies
 Project Readme

sparkle-pack-shell-helpers

This is SparklePack to abstract some configuration tweaks you'd need while deploying Rails app.

It is in experimental state, use at your own risk.

Usage

Add the pack to your Gemfile and .sfn:

Gemfile:

source 'https://rubygems.org'

gem 'sfn'
gem 'sparkle-pack-rails-helpers'

.sfn:

Configuration.new do
  sparkle_pack [ 'sparkle-pack-rails-helpers' ]
  ...
end

In a SparkleFormation template use as needed:

user_data registry!(:rails_database_url,
             adapter: 'mysql2',
             host: ref!(:db_address),
             port: 3306,
             database: ref!(:db_name),
             username: 'foo',
             password: 'bar')

This produces the following UserData:

{ "Fn::Join": [
  "",
  [
    "mysql2", "://", "foo", ":", "bar",
    {
      "Ref": "DbAddress"
    },
    ":", "3306", "/",
    {
      "Ref": "DbName"
    }
  ]
]}

Contributions

Pull requests and bug reports are welcome.

License and authors