Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/KamilLelonek/Ansible-Ruby-DirectoryStatus

Ruby library for Ansible that checks given directory status
https://github.com/KamilLelonek/Ansible-Ruby-DirectoryStatus

Last synced: 3 months ago
JSON representation

Ruby library for Ansible that checks given directory status

Awesome Lists containing this project

README

        

# Ansible-Ruby-DirectoryStatus

This is an example of ruby library to be executed by Ansible.

## Setup

vagrant up

## Run

vagrant provision

## Usage

You can find the usage by looking either at `status.yml` or at library code itself (`library/status`).

## Description

You can call action for given path:

- name: call status action
status: dir_path=/
register: status_of_path

The `status_of_path` will be the following json:

{
exists: true/false
directory: true/false (if file or when not exists)
empty: true/false/none (in case of file)
}