Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mgrachev/capistrano-hanami
🌸 Hanami tasks for Capistrano
https://github.com/mgrachev/capistrano-hanami
capistrano deployment hanami ruby
Last synced: 25 days ago
JSON representation
🌸 Hanami tasks for Capistrano
- Host: GitHub
- URL: https://github.com/mgrachev/capistrano-hanami
- Owner: mgrachev
- License: mit
- Archived: true
- Created: 2016-12-31T12:16:49.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-01-07T16:55:42.000Z (almost 5 years ago)
- Last Synced: 2024-10-31T15:08:06.587Z (about 1 month ago)
- Topics: capistrano, deployment, hanami, ruby
- Language: Ruby
- Homepage: https://www.mgrachev.com/projects
- Size: 12.7 KB
- Stars: 11
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-hanami - capistrano-hanami - Hanami tasks for [Capistrano](https://github.com/capistrano/capistrano). (Hanami Gem List / Deploy)
README
# 🌸 Capistrano::Hanami
[Hanami](https://github.com/hanami/hanami) tasks for [Capistrano](https://github.com/capistrano/capistrano) v3:
- `cap deploy:migrate`
- `cap deploy:compile_assets`## Installation
Add this line to your application's Gemfile:
```ruby
group :development do
gem 'capistrano', '~> 3.7'
gem 'capistrano-hanami', require: false
end
```And then execute:
$ bundle
Then run the generator to create a basic set of configuration files:
$ bundle exec cap install
## Usage
```ruby
# Capfile
require 'capistrano/hanami' # It also requires bundler
```You can tweak some Hanami-specific options in `config/deploy.rb`:
```ruby
# If the environment differs from the stage name
set :hanami_env, 'staging'# Defaults to :app role
set :migration_role, :db# Defaults to the primary :app server
set :migration_servers, -> { primary(fetch(:migration_role)) }# Defaults to false
# Skip migration if files in db/migrations were not modified
set :conditionally_migrate, true# Defaults to [:web]
set :assets_roles, [:web, :app]
```## Development
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
## Contributing
Bug reports and pull requests are welcome on GitHub at https://github.com/mgrachev/capistrano-hanami.