https://github.com/remedyit/inprovise-file
File action extension for Inprovise scripts
https://github.com/remedyit/inprovise-file
Last synced: 2 months ago
JSON representation
File action extension for Inprovise scripts
- Host: GitHub
- URL: https://github.com/remedyit/inprovise-file
- Owner: RemedyIT
- Created: 2016-08-29T11:52:24.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2021-02-01T09:35:50.000Z (over 4 years ago)
- Last Synced: 2025-02-13T08:52:47.856Z (4 months ago)
- Language: Ruby
- Size: 14.6 KB
- Stars: 1
- Watchers: 4
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Inprovise File dependency
=========================This project implements an extension for the Inprovise provisioning tool providing a `file` command to the basic
Inprovise scripts.[](https://travis-ci.org/mcorino/Inprovise-File)
[](https://codeclimate.com/github/RemedyIT/Inprovise-File)
[](https://codeclimate.com/github/RemedyIT/Inprovise-File/coverage)
[](https://badge.fury.io/rb/inprovise-file)Installation
------------$ gem install inprovise-file
Usage
-----Add the following to (for example) your Inprovise project's `rigrc` file.
````ruby
require 'inprovise/file'
````Syntax
------````ruby
file({
:source => '/local/source/path', # alternatively provide block returning path string
:destination => '/remote/destination/path', # alternatively provide block returning path string
:create_dirs => true, # alternatively provide block returning boolean
:permissions => 0644, # alternatively provide block returning permissions
:group => 'users', # alternatively provide block returning group id
:user => 'userid' # alternatively provide block returning user id
}) [ do ... end] # optional action block
````or
````ruby
file({
:template => '/local/template/path', # alternatively provide block returning inline ERB template
:destination => '/remote/destination/path', # alternatively provide block returning path string
:create_dirs => true, # alternatively provide block returning boolean
:permissions => 0644, # alternatively provide block returning permissions
:group => 'users', # alternatively provide block returning group id
:user => 'userid' # alternatively provide block returning user id
}) [ do ... end] # optional action block
````Providing `:source` and `:destination` is mandatory.
All other settings are optional.