Git Product home page Git Product logo

nlew-floaty's Introduction

floaty

Table of Contents

  1. Description
  2. Setup - The basics of getting started with floaty
  3. Usage - Configuration options and additional functionality
  4. Reference - An under-the-hood peek at what the module is doing and how
  5. Limitations - OS compatibility, etc.
  6. Development - Guide for contributing to the module

Description

This module provides Puppet tasks and functions that use vmfloaty to interact with Puppet's vmpooler application.

Setup

Currently, this module requires that the vmfloaty gem is installed on the target node and that any necessary configuration is present in ~/.vmfloaty.yml:

url: https://vmpooler.example.com
token: '<vmpooler_api_token>'

Usage

The simplest way to test out the module is to run it against localhost with Bolt:

$ bolt task run floaty::get platform=centos-7-x86_64 count=2 --nodes localhost
Started on localhost...
Finished on localhost:
  {
    "nodes": [
      "t8vhnjwomf59htp.example.com",
      "ft0jdxrgv899r0r.example.com"
    ]
  }
Successful on 1 node: localhost
Ran on 1 node in 0.52 seconds

Reference

Tasks

floaty::get

This task retrieve a set of nodes from vmpooler.

Parameters

platform : Which VM pool to retrieve nodes from (ie. centos-7-x86_64)
count : How many nodes to retrieve (defaults to 1 if not specified)

Output

On success, the result will contain a nodes key, which is an array of the retrieved nodes. On failure, the result will contain an _error key describing the problem.

Functions

floaty::get(platform, count)

This function retrieves a node or list of nodes from vmpooler by running floaty locally.

Parameters

platform : Which VM pool to retrieve nodes from (ie. centos-7-x86_64)
count : How many nodes to retrieve (defaults to 1 if not specified)

Value

If one node was requested, the value is the name of node retrieved. If multiple nodes were requested, the value is an array of retrieved node names.

Limitations

This module is currently only intended to solve a very specific use case, so it's probably quite fragile in cases where floaty itself isn't set up properly.

Currently, the floaty::get task only supports retrieving nodes from one pool at a time.

Use with caution.

Development

Pull requests welcome!

nlew-floaty's People

Contributors

nicklewis avatar

Watchers

James Cloos avatar

Forkers

lucywyman ccaum

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.