Sha256: 0f695a6468092163ef4d07367244e985d7270f71ef94ea678192d233a338666a
Contents?: true
Size: 582 Bytes
Versions: 1
Compression:
Stored size: 582 Bytes
Contents
module Meroku module CLI # Logic related to apiusername, apipassword and the env file module Secrets def self.load(admin: false) return unless admin env_file = Dir.home + '/.meroku/meroku.env' attempt_download unless File.exist?(env_file) Dotenv.load(env_file) end def self.attempt_download abort 'ENV["SECRET"] not found' unless ENV['SECRET'] FileUtils.mkdir_p "#{Dir.home}/.meroku" `curl -so ~/.meroku/meroku.env https://s3.amazonaws.com/#{ENV['SECRET']}/meroku.env` end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
meroku-2.0.18 | lib/meroku/cli/secrets.rb |