Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save vwall/8423949 to your computer and use it in GitHub Desktop.
Save vwall/8423949 to your computer and use it in GitHub Desktop.
# Assuming that you have followed all the instructions from https://github.com/rumblelabs/asset_sync
# Put this in your deployment script
# Choose any environment here the important part is that your environment is using the same bucket for all environments
# than you only need to precompile assets once
RAILS_ENV=staging bundle exec rake assets:precompile
# You need to set git credentials otherwise it won't be able to commit
git config --global user.email "codeship@codeship.com"
git config --global user.name "Codeship Server"
# Add your manifest file so that rails can find digested version of files
git add --force public/assets/manifest*.json
# Commit with special --skip-ci command which indicates to codeship to ignore this commit. To avoid infinite build.
git commit -m "Update assets --skip-ci"
# Because it's in detached head a bit funky syntax required to push changes back to your master
git push git@github.com:<owner/name_of_your_repo>.git HEAD:master
# .cloud66/manifest.yml
development:
rails:
configuration:
use_asset_pipeline: false
qa:
rails:
configuration:
use_asset_pipeline: false
staging:
rails:
configuration:
use_asset_pipeline: false
production:
rails:
configuration:
use_asset_pipeline: false
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment