Skip to content

Releases: katzer/ski

1.5.2

27 Aug 19:55
Compare
Choose a tag to compare

What's new

Released at: 27.08.2024

  1. Use SSH Agent instead of $ORBIT_KEY for authentication.

  2. Run command in a local shell for planets of type other then server or database.

  3. Compiled binary for OSX build with MacOSX11.3 SDK.

  4. Added binary for arm64-apple-darwin19 target.

  5. Upgraded to mruby 3.2.0

Full Changelog

1.5.1

18 Mar 17:21
Compare
Choose a tag to compare

What's new

Released at: 18.03.2020

  1. Singularized folder names.

  2. Fixed potential memory leaks.

  3. Compiled with MRB_WITHOUT_FLOAT.

  4. Compiled binary for OSX build with MacOSX10.15 SDK.

  5. Upgraded to mruby 2.1.0

Full Changelog

1.5.0

13 Aug 22:35
Compare
Choose a tag to compare

What's new

Released at: 13.08.2019

  1. Added support for ECDSA for both key exchange and host key algorithms

  2. Compiled binary for OSX build with MacOSX10.13 SDK (Darwin17)

  3. Upgraded to mruby 2.0.1

Full Changelog

1.4.7

02 Jan 08:55
Compare
Choose a tag to compare

Whats new

  1. Dropped compatibility with orbit v1.4.6 due to breaking changes in fifa.

  2. Removed LVAR section for non test builds.

  3. Upgraded to mruby 2.0.0

1.4.6

16 Aug 16:40
Compare
Choose a tag to compare

Whats new

Tool has been fully reworked.

$ ski -h

usage: ski [options...] matchers...
Options:
-c, --command   Execute command and return result
-s, --script    Execute script and return result
-t, --template  Template to be used to transform the output
-j, --job       Execute job specified in file
-n, --no-color  Print errors without colors
-p, --pretty    Pretty print output as a table
-w, --width     Width of output column in characters
-h, --help      This help text
-v, --version   Show version number

Commands

Execute shell commands:

$ ski -c 'echo Greetings from $PACKAGE_NAME' mars pluto

Greetings from Mars
Greetings from Pluto

Execute shell scripts:

$ ski -s greet.sh mars pluto

Execute SQL commands:

$ ski -c 'SELECT * FROM DUAL' db

D
-
X

Execute SQL scripts:

$ ski -s dummy.sql db

Pretty table output:

$ ski -p -c env localhost

+-----+-----------+--------+----------------+------+--------------------------------------------------------+
|                                          ski -p -c env localhost                                          |
+-----+-----------+--------+----------------+------+--------------------------------------------------------+
| NR. | ID        | TYPE   | CONNECTION     | NAME | OUTPUT                                                 |
+-----+-----------+--------+----------------+------+--------------------------------------------------------+
|  1. | localhost | server | root@localhost | Host | SSH_CONNECTION=127.0.0.1 49154 127.0.0.1 22            |
|     |           |        |                |      | USER=root                                              |
|     |           |        |                |      | PWD=/root                                              |
|     |           |        |                |      | HOME=/root                                             |
|     |           |        |                |      | SSH_CLIENT=127.0.0.1 49154 22                          |
|     |           |        |                |      | MAIL=/var/mail/root                                    |
|     |           |        |                |      | SHELL=/bin/bash                                        |
|     |           |        |                |      | SHLVL=1                                                |
|     |           |        |                |      | LOGNAME=root                                           |
|     |           |        |                |      | PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin |
|     |           |        |                |      | _=/usr/bin/env                                         |
+-----+-----------+--------+----------------+------+--------------------------------------------------------+

Templates

Execute a shell or SQL command or script and convert the output based on a [TextFSM][textfsm] template.

$ ski -s vparams.sql -t vparams db

The SQL script could look like this:

SET PAGESIZE 0
SET NEWPAGE 0
SET SPACE 0
SET LINESIZE 18000
SET WRAP OFF
SET FEEDBACK OFF
SET ECHO OFF
SET VERIFY OFF
SET HEADING OFF
SET TAB OFF
SET COLSEP ' , '

SELECT NUM, NAME, VALUE FROM V$PARAMETER WHERE NUM IN (526, 530);

The template file could look like this:

$ cat $ORBIT_HOME/templates/vparams.textfsm

Value Num (\d+)
Value Name (\S*)
Value Value (\S*)

Start
  ^ *${Num}[ |,]*${Name}[ |,]*${Value} -> Record

Jobs

Bundle command-line arguments to a job to save the report output.

$ ski -j vparams

The job file could look like this:

$ cat $ORBIT_HOME/jobs/vparams.skijob

-s vparam.sql -t vparam db

The report result could look like this:

$ cat $ORBIT_HOME/reports/vparams/1531410936.skirep

1531410936
[["Num", "int"], ["Name", "string"], ["Value", "string"]]
["db","Operativ DB",true,["526", "optimizer_adaptive_plans", "FALSE"]]
["db","Operativ DB",true,["530", "optimizer_adaptive_statistics", "FALSE"]]

1.4.4

30 Nov 11:55
Compare
Choose a tag to compare
release fix

0.9.1

15 Feb 14:33
Compare
Choose a tag to compare
0.9.1 Pre-release
Pre-release

Whats new

  • Renamed the Project from goo to ski
  • Extended functionality, so SQL commands and scripts can be executed on database-type planets
  • Supports formatting output via a template into JSON format via the -t flag.

Without formatting:

    $ ski -s="showver.sh" app
    willywonka version check 2.1
    -----------------------

    willywonka blueberrychocolate factory London OompaLoompa_Headquarters
    -[binaries]---------------------------------------------------------------------
      gateway         4.6.1.1 (build time Oct 21 2015 10:35:11)
      telhandlerkm    4.6.0.2 (build time Oct 13 2016 12:00:31)
      ...

With formatting:

    $ ski -s="showver.sh" -t="perlver_template" app
    [
    ["willywonka_version", "Section", "Suse", "UnixVersion", "UnixPatch", "Key", "Value", "Key2", "Value2", "Os", "OracleDb"],
    ["2.1", "", "", "", "", "", "", "", "", "", ""],
    ["", "binaries", "", "", "", "", "", "", "", "", ""],
    ...
    ]
  • Supports formatting output into a prettyprinted ascii-table via the -p flag.
    $ ski -s="showver.sh" -t="perlver_template" -p app
    | willywonka_version | Section  | gateway                                   |
     -----------------------------------------------------------------------------
    | 2.1                | binaries | 4.6.1.1 (build time Oct 21 2015 10:35:11) |
  • Supports loading the users bash profile fur bash remote bash executions.
  • Creates a logfile and writes down whats happening.
    logfile.log:
    [34mINFO[0m[2017-02-15 15:04:56] Started with args: [./ski -s=shover.sh app]

    [31mFATA[0m[2017-02-15 15:04:56] open /root/code/bintest/testFolder/scripts/shover.sh: no such file or directory
    Additional info: called from uploadFile. Keypath: /.ssh/orbit.key

    [34mINFO[0m[2017-02-15 15:05:17] Started with args: [./ski -s=showver.sh app]
  • Looks for ssh-keyfile called orbit.key at ../config/ssh/ if no ORBIT_KEY enviromental variable is provided.
  • Scripts to be executed need to be saved in ../scripts/
  • Templates to be used need to be saved in ../templates/

0.9

12 Dec 15:11
Compare
Choose a tag to compare
0.9 Pre-release
Pre-release

Whats new

  • Added multi-planet-execution-support
  • Added option -s="pathToScript" to specify a bash script to be uploaded and executed on a planet
  • Added option -p for prettyprinting the output in a neat, readable manner
  • Changed the ssh authentification handling in a way that goo looks for a keyfile at $ORBIT_KEY rather than relying on the keyfile being managed by the ssh-manager

0.0.1

18 Nov 12:12
Compare
Choose a tag to compare
0.0.1 Pre-release
Pre-release

Whats new

First Version

  • bash command execution per ssh on given planet