Commit graph

79 commits

Author SHA1 Message Date
Jake Spain
d5d87ed54a
Fix floaty list --active for vmpooler api v2 2023-03-20 15:06:28 -04:00
Jake Spain
667dacbcea
Add ondemand flag and api v2 support to floaty ssh 2022-04-05 11:41:44 -04:00
Jake Spain
4103fdeccc
Add VMPooler api v2 support for floaty get 2022-04-04 14:14:40 -04:00
Samuel Beaulieu
6b9b4ea626
(DIO-2700) Vmfloaty should not use the Colorize gem
removing cosmetic use of colorize
2022-02-16 13:07:05 -06:00
38a465e862
Migrate CI to GitHub Actions 2021-07-16 17:13:51 -04:00
Nick Burgan-Illig
f6febc9b8f (maint) Use latest Faraday/webmock, update specs
This unpins Faraday and webmock, and updates specs so that the Faraday changes (primarily including auth in the header rather than in the URL) is reflected.
2021-07-12 18:33:50 +00:00
Samuel Beaulieu
eb99ba1dec
Run the rubocop auto_correct
fixed 27 files inspected, 975 offenses detected, 804 offenses corrected
2021-02-25 13:38:11 -06:00
Samuel Beaulieu
8143641f83
(DIO-1522) Show the VM state (running, destroyed) and colorize in red when it has been deleted
the ABS system does not have a real sense of the current state of the resources
it has allocated. When running list --active it can list VMs that have been
deleted or reaped after their lifetime expired.
This change enables to show more information when a vmpooler_fallback service
is provided to ABS, and will show the state (running, destroyed) and colorize
in red when the VM is destroyed.
2021-02-25 10:14:41 -06:00
Samuel Beaulieu
4aa78a1b66 fix tests 2020-10-16 13:23:50 -05:00
Samuel Beaulieu
6deadb2267 Fix tests 2020-09-24 10:00:15 -05:00
bc1ea2e2d9
Merge pull request #90 from scotje/add_zsh_completions_new
Add tab completion script for zsh and fix bash completion for ABS services
2020-09-22 11:56:31 -04:00
Samuel Beaulieu
2b56448d50 Fix pretty print when multiple backend services
are returned by ABS. Added test with vmpooler and nspooler result
2020-09-22 09:53:13 -05:00
Samuel Beaulieu
45f0ef031e Fix spec tests for ABS pretty print
ABS now returns the ABS job_id on the first line, then every
vmpooler hostname indented. It queries them from vmpooler to
get the metadata like lifetime etc
2020-09-22 09:15:15 -05:00
Jesse Scott
8546c1c4b6
WIP: fixup specs after rebase 2020-09-21 16:59:04 -07:00
Jesse Scott
b31f44fb40
Add --hostnameonly option to floaty list --active
Adds an option to the `floaty list` subcommand so that, when listing
active hosts, floaty will output just the hostnames, without any
additional information or formatting. Hostnames will be separated by a
newline.

This functionality is primarily intended for consuming by tooling (such
as the tab completion scripts).
2020-09-21 16:55:07 -07:00
Samuel Beaulieu
cd7c0fae13 Adding spec tests for #list 2020-09-21 15:20:22 -05:00
Samuel Beaulieu
4df970b21f (maint) Fix for ABS PR#306 that includes json responses
Before this change ABS sometiimes returned a string of JSON with escaped
quotes, that had to be parsed again
With this change, floaty should accept both the legacy and the new
full JSON responses.
2020-09-21 14:46:00 -05:00
mattkirby
f3cd540455
Merge pull request #98 from puppetlabs/better-abs-config
(maint) Support any vmpooler for ABS via vmpooler_fallback
2020-09-17 10:08:05 -07:00
mattkirby
81c6e48528
Merge pull request #97 from puppetlabs/types-docs
(DIO-991) Add service command
2020-09-17 08:58:24 -07:00
9e61247cfe
Add service command
This change creates the `floaty service` command with two valid
arguemnts: types and examples

- `floaty service types` prints out a list of valid types for use in a
  service definition in ~/.vmfloaty.yml
- `floaty service examples` prints out example configuration files for
  both a single service and multiple services.
2020-09-16 12:55:42 -04:00
Samuel Beaulieu
5333158bdc (maint) Support any vmpooler for ABS via vmpooler_fallback
Before this change, the fallback vmpooler for ABS had to be named
'vmpooler' and it only supported one. With this new code, users can
set a key within an 'abs' service type called vmpooler_fallback that
points to any other service configured in the ~/.vmfloaty.yml config
file. If not set, the appropriate error message is returned, with
an example configuration.
Added the various use cases for the config to the unit tests
2020-09-16 11:25:49 -05:00
Samuel Beaulieu
4b7cbbf0e5 fix abs spec tests 2020-09-15 11:21:58 -05:00
Austin Blatt
4755343df2 Print all non-success output to STDERR 2020-08-10 16:20:25 -07:00
kirby@puppetlabs.com
05a133fc72 Add support for ondemand provisioning to vmfloaty
This commit adds support for provisioning instances on demand with
vmpooler. Additionally, this change adds a capability to detect on
demand pools available in ABS. Without this change vmfloaty does not
support provisioning instances via the vmpooler ondemand endpoints.
2020-08-04 11:24:11 -07:00
a6f53c0310
Add Dependabot and Coveralls
This adds Dependabot to keep things updated and Coveralls so we can see
how code coverage changes over time. Coveralls / SimpleCov are
configured so that both the SimpleCov html report and the Coveralls
report are generated. This facilitates easily seeing coverage locally in
addtion to via CI.
2020-07-07 10:17:10 -04:00
Brian Cain
5dbe19e10b
Merge branch 'master' into qeng-7604_add_jobid_to_delete 2020-01-28 13:40:53 -08:00
Mikker Gimenez-Peterson
ac14629eb3 SSH Command respects ABS now and tests should fail if the API changes again 2020-01-27 15:29:00 -08:00
Brandon High
51a7eb809e
(QENG-7604) Add support for Job IDs to ABS delete
This commit adds support for passing in a JobID when deleting with ABS.
2020-01-27 14:17:06 -08:00
Mikker Gimenez-Peterson
dc3bfecd28 Adding spec test to ensure that all the interfaces are the same, while doing so, fix the broken interfaces for delete on vmpooler and nonstandard pooler(they were passed 5 by service.rb but expected 4) 2020-01-14 09:45:28 -08:00
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