Commit graph

50 commits

Author SHA1 Message Date
Mikker Gimenez-Peterson
2c456f1157 ABS will sometimes return null values in the /status/queue endpoint 2019-12-16 16:13:33 -08:00
Mikker Gimenez-Peterson
d963e357d3 Adding delete and get active requests 2019-12-04 11:37:17 -08:00
Mikker Gimenez-Peterson
7e27542670 Adding delete and get active requests 2019-11-04 11:41:49 -08:00
Mikker Gimenez-Peterson
a77ea84092 Rebasing fixed tests 2019-10-31 14:25:47 -07:00
Mikker Gimenez-Peterson
de7d0fdeab Adding command to list pools out of ABS 2019-10-31 11:33:07 -07:00
Brandon High
c140e7af48
Update Faraday to 0.15, remove unnecessary headers 2019-10-22 13:28:14 -07:00
Tim Sharpe
c78ad33104 (rubocop) Fix Layout/LeadingCommentSpace 2019-02-03 13:12:33 +11:00
Tim Sharpe
7d9545f202 (rubocop) Fix Layout/IndentHeredoc 2019-02-03 13:11:07 +11:00
Tim Sharpe
851009b1f6 (rubocop) Fix Layout/AlignHash & Layout/IndentHash 2019-02-03 13:08:00 +11:00
Tim Sharpe
f2ab052fa4 (rubocop) Fix Layout/ExtraSpacing 2019-02-03 12:49:03 +11:00
Tim Sharpe
9afae18ee2 (rubocop) Fix Layout/SpaceAfterComma 2019-02-03 12:48:04 +11:00
Tim Sharpe
edaa3e5645 (rubocop) Fix Layout/EmptyLinesAroundBlockBody 2019-02-03 12:41:22 +11:00
Tim Sharpe
b2ac1ddf2f (rubocop) Fix Layout/MultilineMethodCallIndentation 2019-02-03 12:39:47 +11:00
Tim Sharpe
6f40397136 (rubocop) Fix Layout/DotPosition 2019-02-03 12:36:47 +11:00
Tim Sharpe
fd753ba188 (rubocop) Fix Layout/SpaceBeforeBlockBraces 2019-02-03 12:34:24 +11:00
Tim Sharpe
b8971c040a (rubocop) Fix Layout/SpaceInsideLiteralHashBraces 2019-02-03 12:32:05 +11:00
Tim Sharpe
b16e3fc792 (rubocop) Fix Layout/SpaceAroundOperators 2019-02-03 12:26:38 +11:00
Tim Sharpe
58f64b2843 (rubocop) Fix Style/TrailingCommaInHashLiteral 2019-02-03 12:22:41 +11:00
Tim Sharpe
095ac9e75e (rubocop) Fix Style/WordArray 2019-02-03 12:22:41 +11:00
Tim Sharpe
cdb9b0ca3d (rubocop) Fix Style/NestedParenthesizedCalls 2019-02-03 12:22:41 +11:00
Tim Sharpe
d95c6946b8 (rubocop) Fix Style/BracesAroundHashParameters 2019-02-03 12:22:41 +11:00
Tim Sharpe
fcf7154a8b (rubocop) Style/HashSyntax to use hash_rockets for consistency 2019-02-03 12:22:41 +11:00
Tim Sharpe
e0cbf89b8f (rubocop) Fix Style/FrozenStringLiteralComment 2019-02-03 12:22:41 +11:00
Tim Sharpe
1272343cdd (rubocop) Fix Style/StringLiterals 2019-02-03 10:42:28 +11:00
Nick Lewis
50eeb8f265 Add --json option for floaty get
This option will return structured output from `floaty get`, which is
easier to parse in some cases.

Example output:

```json
{
  "centos-7-x86_64": [
    "hpfhhf5aqxowfd8.delivery.puppetlabs.net",
    "k65euywltpz9fz0.delivery.puppetlabs.net"
  ],
  "centos-6-x86_64": [
    "oahunrurl7xis05.delivery.puppetlabs.net"
  ]
}
```
2018-01-02 10:23:54 -08:00
Casey Williams
ca5b0f5e8b Integrate nonstandard pooler service into vmfloaty 2017-10-12 12:53:04 -07:00
Casey Williams
e78bcc6216 Allow configuration of multiple services 2017-09-25 15:23:10 -07:00
Ryan McKern
ee0c73dfda Add a little formatting to Rspec 2017-03-01 14:02:58 -08:00
Brian Cain
a6ff0515d3 Raise TokenError if none provided to Pooler.delete 2016-11-14 09:49:23 -08:00
Brian Cain
b51a549fe5 (#34) Raise TokenError on operations that require tokens
Prior to this commit, the Pooler class would raise an exception if the
token provided was nil and it attempted to make a request with Faraday.
This fixes that by catching when nil tokens are provided and instead
raising a TokenError to be caught by the consumer.
2016-10-07 18:10:52 -07:00
Brian Cain
579320e988 (#33) Raise TokenError if no token provided 2016-09-24 11:15:44 -07:00
Brian Cain
8da1deaf6b (#33) Handle Auth class errors
This commit updates the Auth class to properly raise an error when
something goes wrong. It also updates the vmpooler command class to
handle when those errors get raised.
2016-09-24 11:11:14 -07:00
Brian Cain
05e9d5a0cc (#32) Handle vmpooler responses when token is invalid
This commit adds an errors class to handle when pooler tokens are
invalid. The retrieve method in Pooler will raise an AuthError if it
gets an HTTP 401 from the vmpooler.
2016-09-24 10:22:48 -07:00
Brian Cain
1d0fc42c80 (#31) Improve how users can provide arguments to commands
Prior this commit, some commands did not accept some options as an
argument and instead only worked through a flag. This commit updates
that behavior to allow users to specify some options through arguments,
while leaving the ability to continue to specify those options through
flags. Command line arguments take precedence over flags. It also fixes
an issue where if a snapshot sha was nil, it would submit a request to
take a snapshot to vmpooler.
2016-09-17 16:07:21 -07:00
Brian Cain
53868b9532 Change useragent for faraday 2016-07-09 20:03:08 -07:00
Brian Cain
5f6cd1df1d (#25) Remove printing from delete method in pooler api 2016-07-09 19:53:12 -07:00
Brian Cain
a6c5f1dceb (#24) Improve 'get' output
This commit updates how hosts are formated when shown to the user. It
applies a domain to each hostname instead of being a different key.
2016-07-02 11:41:02 -07:00
Justin Stoller
1dd8230017 (maint) Include tags in host pretty printing when available 2016-06-03 10:45:34 -07:00
Brian Cain
a0b0016bcd Add spec test for formatting hashes 2015-11-15 14:35:25 -08:00
Brian Cain
c6cf86669a Cleanup vmfloaty library and command line functions 2015-11-15 14:24:24 -08:00
Brian Cain
3394a14ea0 (#14) Remove printing in auth library 2015-11-15 13:27:07 -08:00
Brian Cain
a0ba604006 (#11) Provide a way to delete all vms acquired by token
This commit adds a way for a user to delete all vms that were obtained
by a specific token. It will ask the user if they are sure before
deleting everything.
2015-11-13 11:52:01 -08:00
Brian Cain
bc4cff5363 (maint) Have pooler delete class take array
Prior to this commit, the pooler class was expecting a comma separated
string of hosts to delete. This commit updates that to expect hostnames
to be an array instead.
2015-11-10 11:42:56 -08:00
Brian Cain
fa92da5c05 (maint) Update token status to not require password 2015-11-05 13:28:37 -08:00
Brian Cain
b62cffa2cd (spec) Add format spec test 2015-10-21 22:21:13 -07:00
Brian Cain
ac12ea69c1 (spec) Add auth class spec tests 2015-10-21 22:08:48 -07:00
Brian Cain
4cf77bc4d4 Fix modify spec test for requests 2015-10-16 15:41:09 -07:00
Brian Cain
beeac3858c (spec) Add spec tests for Pooler class 2015-10-13 22:43:00 -07:00
Brian Cain
e613a6818d Initial commit of test framework 2015-10-09 22:26:20 -07:00
Brian Cain
99b03e2994 Initial commit of vmfloaty 2014-10-28 22:05:33 -07:00