Skip to content

Commit

Permalink
adding (encrypted) s3 credentials to travis
Browse files Browse the repository at this point in the history
  • Loading branch information
ciscou committed Dec 9, 2013
1 parent c5cf47f commit 03dce1b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 5 additions & 1 deletion .travis.yml
@@ -1,6 +1,10 @@
language: ruby
before_script:
- psql -c 'create database cpp_development;' -U postgres
- mv config/s3.yml.example config/s3.yml
rvm:
- 2.0.0
env:
global:
- secure: GiQTAiHHfD27FPk0/jV5dZIrHK+refypoxwnXe5MLOB5ND2ZupGKzPFcO7E5VcIdnIwX1+UNVj9crv8YdNnyaRozuLuBVWGtfzJP8C4J4ZOarr0UMyhyAz4JvbbkT1oGrL8xkpZ+u4JQWvxJbzEGExv/8mPkgHbxdr5izMX3QNo=
- secure: YuNUEmbW94JFwBDayoStaM43RG72th9cP6/fFFvUFKJ0Qm7Rw5OXFU5ypqwOSvQFhNBuRZmME4fxgejZQ7ojuevZwX515Zm/ZD0BUGSbY3Vz4BS2vqeMGPX93F0IaC3XFnW7RgViWQ1H+XV9RwIFC3+JJhE4aKDR0Gr2pkhlhCs=
- S3_BUCKET=ceramicapadilladev
6 changes: 3 additions & 3 deletions config/initializers/carrierwave.rb
@@ -1,4 +1,6 @@
S3_CONFIG = if Rails.env.production?
S3_CONFIG = if File.exists? Rails.root.join("config", "s3.yml")
YAML.load_file Rails.root.join("config", "s3.yml")
else
{
"fog_credentials" => {
"provider" => 'AWS',
Expand All @@ -7,8 +9,6 @@
},
"fog_directory" => ENV["S3_BUCKET"]
}
else
YAML.load_file Rails.root.join("config", "s3.yml")
end
S3_CONFIG.symbolize_keys!

Expand Down

0 comments on commit 03dce1b

Please sign in to comment.