Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jawnnypoo/dropbox-deployment
Deploy your CI artifacts to Dropbox
https://github.com/jawnnypoo/dropbox-deployment
ci deployment dropbox ruby travis-ci
Last synced: 3 months ago
JSON representation
Deploy your CI artifacts to Dropbox
- Host: GitHub
- URL: https://github.com/jawnnypoo/dropbox-deployment
- Owner: Jawnnypoo
- License: mit
- Created: 2017-03-19T06:10:24.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2019-02-22T22:12:30.000Z (almost 6 years ago)
- Last Synced: 2024-04-25T06:02:18.242Z (9 months ago)
- Topics: ci, deployment, dropbox, ruby, travis-ci
- Language: Ruby
- Size: 17.6 KB
- Stars: 9
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# dropbox-deployment
Deploy your CI artifacts to Dropbox[![Build Status](https://travis-ci.org/Jawnnypoo/dropbox-deployment.svg?branch=master)](https://travis-ci.org/Jawnnypoo/dropbox-deployment)
[![Gem](https://img.shields.io/gem/v/dropbox-deployment.svg)](https://rubygems.org/gems/dropbox-deployment)## Setup
Install the gem:
```
gem install dropbox-deployment
```
This may vary in where this should go depending on your CI setup.
If you are using Travis, it would look something like:
```
before_install:
- rvm install 2.2.6
- gem install dropbox-deployment
```
## Usage
Similar to the [dropbox_api](https://github.com/Jesus/dropbox_api), you need to have an environment variable called `DROPBOX_OAUTH_BEARER`You can create a OAUTH token here:
https://www.dropbox.com/developers/apps/createDeployment looks for a `dropbox-deployment.yml` file in order to configure where the artifacts are and where they should go.
For example:
```yml
deploy:
dropbox_path: /Builds # The path to the folder on Dropbox where the files will go
artifacts_path: artifacts # can be a single file, or a path
debug: true # if you want to see more logs
```
After creating this configuration, all you need to do is run:
```shell
dropbox-deployment
```
This place where this goes also can vary depending on the CI setup.
If you are using Travis, you would want this as follows:
```
after_success:
- dropbox-deployment
```## Limitations
Since we rely on a certain function of the Ruby Dropbox API client, we are limited to 150 MB per file size. See more [here](http://jesus.github.io/dropbox_api/DropboxApi/Client.html#upload-instance_method)## Test Locally
Just run `ruby test/test.rb`. Set up your `dropbox-deployment.yml` as desired, as well as your `.env` file for your OAUTH token.## Deployment
1. Adjust the version in the gemspec
2. `gem build dropbox-deployment.gemspec`
3. `gem push dropbox-deployment-version.number.here.gem`
4. Tag release in git## Thanks
Thanks to the following for being a great reference on how to create a command line Ruby Gem:
- http://robdodson.me/how-to-write-a-command-line-ruby-gem/## License
dropbox-deployment is available under the MIT license. See the LICENSE file for more info.