aspera-cli 4.20.0 → 4.21.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. checksums.yaml +4 -4
  2. checksums.yaml.gz.sig +0 -0
  3. data/CHANGELOG.md +20 -2
  4. data/README.md +281 -156
  5. data/bin/asession +2 -2
  6. data/lib/aspera/agent/alpha.rb +7 -12
  7. data/lib/aspera/agent/connect.rb +19 -1
  8. data/lib/aspera/agent/direct.rb +20 -29
  9. data/lib/aspera/agent/node.rb +1 -11
  10. data/lib/aspera/agent/trsdk.rb +4 -25
  11. data/lib/aspera/api/aoc.rb +5 -0
  12. data/lib/aspera/api/node.rb +45 -28
  13. data/lib/aspera/ascp/installation.rb +69 -38
  14. data/lib/aspera/ascp/management.rb +27 -6
  15. data/lib/aspera/cli/formatter.rb +149 -141
  16. data/lib/aspera/cli/info.rb +1 -1
  17. data/lib/aspera/cli/manager.rb +1 -0
  18. data/lib/aspera/cli/plugin.rb +2 -2
  19. data/lib/aspera/cli/plugins/aoc.rb +27 -17
  20. data/lib/aspera/cli/plugins/config.rb +31 -21
  21. data/lib/aspera/cli/plugins/faspex.rb +1 -1
  22. data/lib/aspera/cli/plugins/faspex5.rb +11 -3
  23. data/lib/aspera/cli/plugins/node.rb +44 -38
  24. data/lib/aspera/cli/version.rb +1 -1
  25. data/lib/aspera/command_line_builder.rb +1 -1
  26. data/lib/aspera/environment.rb +5 -6
  27. data/lib/aspera/node_simulator.rb +228 -112
  28. data/lib/aspera/oauth/base.rb +31 -42
  29. data/lib/aspera/oauth/factory.rb +41 -2
  30. data/lib/aspera/persistency_folder.rb +20 -2
  31. data/lib/aspera/preview/generator.rb +1 -1
  32. data/lib/aspera/preview/utils.rb +1 -1
  33. data/lib/aspera/products/alpha.rb +30 -0
  34. data/lib/aspera/products/connect.rb +48 -0
  35. data/lib/aspera/products/other.rb +82 -0
  36. data/lib/aspera/products/trsdk.rb +54 -0
  37. data/lib/aspera/rest.rb +18 -13
  38. data/lib/aspera/ssh.rb +28 -24
  39. data/lib/aspera/transfer/spec.yaml +22 -20
  40. data.tar.gz.sig +0 -0
  41. metadata +21 -4
  42. metadata.gz.sig +0 -0
  43. data/lib/aspera/ascp/products.rb +0 -168
data/README.md CHANGED
@@ -5,7 +5,7 @@ Do not edit this README.md, edit docs/README.erb.md, for details, read docs/READ
5
5
  markdownlint-disable MD033 MD003 MD053
6
6
  cspell:ignore Serban Antipolis
7
7
  PANDOC_META_BEGIN
8
- subtitle: "ascli 4.20.0"
8
+ subtitle: "ascli 4.21.0"
9
9
  PANDOC_META_END
10
10
  -->
11
11
 
@@ -15,7 +15,7 @@ PANDOC_META_END
15
15
 
16
16
  ## Introduction
17
17
 
18
- Version : 4.20.0
18
+ Version : 4.21.0
19
19
 
20
20
  Laurent/2016-2025
21
21
 
@@ -27,9 +27,9 @@ Ruby Gem: [https://rubygems.org/gems/aspera-cli](https://rubygems.org/gems/asper
27
27
 
28
28
  Ruby Doc: [https://www.rubydoc.info/gems/aspera-cli](https://www.rubydoc.info/gems/aspera-cli)
29
29
 
30
- Minimum required Ruby version: >= 2.6.
30
+ Minimum required Ruby version: >= 2.7.
31
31
 
32
- > **Deprecation notice**: the minimum Ruby version will be 3.0 in a future version.
32
+ > **Deprecation notice**: the minimum Ruby version will be 3.1 in a future version.
33
33
 
34
34
  [Aspera APIs on IBM developer](https://developer.ibm.com/?size=30&q=aspera&DWContentType[0]=APIs&sort=title_asc)
35
35
  [Link 2](https://developer.ibm.com/apis/catalog/?search=aspera)
@@ -112,7 +112,7 @@ Once the gem is installed, `ascli` shall be accessible:
112
112
 
113
113
  ```console
114
114
  $ ascli --version
115
- 4.20.0
115
+ 4.21.0
116
116
  ```
117
117
 
118
118
  ### First use
@@ -211,9 +211,9 @@ The direct installation is recommended and consists in installing:
211
211
  - [aspera-cli](#ruby-gem-aspera-cli) <!-- markdownlint-disable-line -->
212
212
  - [Aspera SDK (`ascp`)](#fasp-protocol-ascp)
213
213
 
214
- Ruby version: >= 2.6.
214
+ Ruby version: >= 2.7.
215
215
 
216
- > **Deprecation notice**: the minimum Ruby version will be 3.0 in a future version.
216
+ > **Deprecation notice**: the minimum Ruby version will be 3.1 in a future version.
217
217
 
218
218
  The following sections provide information on the various installation methods.
219
219
 
@@ -228,9 +228,9 @@ Use this method to install on the native host (e.g. your Windows, macOS or Linux
228
228
 
229
229
  A Ruby interpreter is required to run `ascli`.
230
230
 
231
- Required Ruby version: >= 2.6.
231
+ Required Ruby version: >= 2.7.
232
232
 
233
- > **Deprecation notice**: the minimum Ruby version will be 3.0 in a future version.
233
+ > **Deprecation notice**: the minimum Ruby version will be 3.1 in a future version.
234
234
 
235
235
  **Ruby can be installed using any method** : rpm, yum, dnf, rvm, brew, Windows installer, ... .
236
236
 
@@ -322,15 +322,17 @@ rubyinstaller-devkit-3.2.2-1-x64.exe /silent /currentuser /noicons /dir=C:\asper
322
322
 
323
323
  #### macOS: `brew`
324
324
 
325
- **macOS** come with Ruby.
326
- Nevertheless, [Apple has deprecated it](https://developer.apple.com/documentation/macos-release-notes/macos-catalina-10_15-release-notes), and it will be removed in the future, so better not to rely on it.
325
+ **macOS** comes with Ruby.
326
+ Nevertheless, it is an old unsupported version and [Apple has deprecated it](https://developer.apple.com/documentation/macos-release-notes/macos-catalina-10_15-release-notes), and it will be removed in the future, so better not to rely on it.
327
327
 
328
- The recommended way is to either user `RVM` or use [Homebrew](https://brew.sh/).
328
+ The recommended way is to either use [Homebrew](https://brew.sh/) or [RVM](https://rvm.io/).
329
329
 
330
330
  ```bash
331
331
  brew install ruby
332
332
  ```
333
333
 
334
+ This installs a recent ruby suitable for `ascli`.
335
+
334
336
  #### Linux: Package
335
337
 
336
338
  If your Linux distribution provides a standard Ruby package, you can use it provided that the version supported.
@@ -738,7 +740,7 @@ ascli -v
738
740
  ```
739
741
 
740
742
  ```text
741
- 4.20.0
743
+ 4.21.0
742
744
  ```
743
745
 
744
746
  In order to keep persistency of configuration on the host, you should specify your user's configuration folder as a volume for the container.
@@ -1501,16 +1503,33 @@ To redirect results to a file, use option `output`.
1501
1503
 
1502
1504
  Depending on action, the output will contain:
1503
1505
 
1504
- - `single_object` : displayed as a 2 dimensional table: one line per attribute, first column is attribute name, and second is attribute value. Nested hashes are collapsed.
1505
- - `object_list` : displayed as a 2 dimensional table: one line per item, one column per attribute.
1506
- - `value_list` : a table with one column.
1507
- - `empty` : nothing
1508
- - `status` : a message
1509
- - `other_struct` : a complex structure that cannot be displayed as an array
1506
+ | Result Type | Description |
1507
+ |-----------------|-------------------|
1508
+ | `single_object` | displayed as a 2 dimensional table: one line per field, first column is field name, and second is field value. Nested hashes are collapsed. |
1509
+ | `object_list` | displayed as a 2 dimensional table: one line per item, one column per field. |
1510
+ | `value_list` | a table with one column. |
1511
+ | `empty` | nothing |
1512
+ | `status` | a message |
1513
+ | `other_struct` | a complex structure that cannot be displayed as an array |
1514
+
1515
+ #### Option: `format`
1516
+
1517
+ The style of output can be set using the `format` option:
1518
+
1519
+ | `format` | Output formatting |
1520
+ |----------|-------------------|
1521
+ | `table` | Text table (default) |
1522
+ | `text` | Value as `String` |
1523
+ | `ruby` | Ruby code |
1524
+ | `json` | JSON code |
1525
+ | `jsonpp` | JSON pretty printed |
1526
+ | `yaml` | YAML |
1527
+ | `csv` | Comma Separated Values |
1528
+ | `image` | Image URL or Image data |
1510
1529
 
1511
- #### Format of output
1530
+ By default, result of type `single_object` and `object_list` are displayed using format `table`.
1512
1531
 
1513
- By default, result of type single_object and object_list are displayed using format `table`.
1532
+ #### Option: `table_style`
1514
1533
 
1515
1534
  The table style can be customized with option: `table_style` which expects a `Hash`, options are the ones described in gem [`terminal-table`](https://github.com/tj/terminal-table).
1516
1535
 
@@ -1522,28 +1541,64 @@ ascli config preset over --table-style=@ruby:'{border: :unicode_thick_edge}'
1522
1541
 
1523
1542
  > **Note:** Other border styles exist, not limited to: `:unicode`, `:unicode_round`.
1524
1543
 
1525
- In a table format, when displaying **Objects** (single, or list), by default, sub object are flattened (option `flat_hash`).
1526
- For example, object `{"user":{"id":1,"name":"toto"}}` will have attributes: `user.id` and `user.name`.
1527
- Setting option `flat_hash` to `false` will only display one field: `user` and value is the sub `Hash`.
1528
- When in flatten mode, it is possible to filter fields using the option `fields` using the compound field name using `.` (dot) as separator.
1544
+ #### Option: `flat_hash`: `.`-join keys
1545
+
1546
+ This optin controls how object fields are displayed for complex objects.
1547
+
1548
+ Effective only when `format` is `table` to display `single_object` or `object_list`.
1549
+
1550
+ If value is `no`, then object's `field` names are only the first level keys of the `Hash` result and values that are `Hash` are displayed as such in Ruby syntax.
1551
+
1552
+ If value is `yes` (default), then object are flattened, i.e. deep `Hash` are transformed into 1-level Hash, where keys are `.`-junction of deep keys.
1553
+ In this case, it is possible to filter fields using the option `fields` using the compound field name using `.` (dot) as separator.
1554
+
1555
+ Example: Result of command is a list of objects with a single object:
1556
+
1557
+ ```console
1558
+ $ ascli conf echo @json:'[{"user":{"id":1,"name":"toto"},"project":"blah"}]'
1559
+ ╭─────────┬───────────┬─────────╮
1560
+ │ user.id │ user.name │ project │
1561
+ ╞═════════╪═══════════╪═════════╡
1562
+ │ 1 │ toto │ blah │
1563
+ ╰─────────┴───────────┴─────────╯
1564
+
1565
+ $ ascli conf echo @json:'[{"user":{"id":1,"name":"toto"},"project":"blah"}]' --flat-hash=no
1566
+ ╭───────────────────────────┬─────────╮
1567
+ │ user │ project │
1568
+ ╞═══════════════════════════╪═════════╡
1569
+ │ {"id"=>1, "name"=>"toto"} │ blah │
1570
+ ╰───────────────────────────┴─────────╯
1571
+ ```
1572
+
1573
+ #### Option: `multi_single`
1574
+
1575
+ This option controls if object fields are displayed as columns or lines.
1576
+
1577
+ If value is `no` (default), `object_list` are displayed with one object per line, with fields as columns (see above).
1578
+ `single_object` are displayed with one field per line (and columns are: `field`, `value`).
1529
1579
 
1530
- Object lists are displayed one per line, with attributes as columns.
1531
- Single objects (or tables with a single result) are transposed: one attribute per line.
1532
- If transposition of single object is not desired, use option: `transpose_single` set to `no`.
1533
- If option `multi_table` is `yes`, then elements of a table are displayed individually in a table.
1580
+ If an `object_list` has a single element, it is possible to have `ascli` display the object as a single object (one field per line instead of columns) with option: `multi_single` set to `single`.
1534
1581
 
1535
- The style of output can be set using the `format` option, supporting:
1582
+ This parameter can be set as a global default with:
1536
1583
 
1537
- - `table` : Text table (default)
1538
- - `text` : Value as String
1539
- - `ruby` : Ruby code
1540
- - `json` : JSON code
1541
- - `jsonpp` : JSON pretty printed
1542
- - `yaml` : YAML
1543
- - `csv` : Comma Separated Values
1544
- - `image` : Image URL or Image data
1584
+ ```bash
1585
+ ascli config preset set GLOBAL multi_single single
1586
+ ```
1587
+
1588
+ In case multiple objects are returned, it is possible to display one table per object with option `multi_single` set to `yes`.
1589
+
1590
+ ```console
1591
+ $ ascli conf echo @json:'[{"user":{"id":1,"name":"toto"},"project":"blash"}]' --multi-single=yes
1592
+ ╭───────────┬───────╮
1593
+ │ field │ value │
1594
+ ╞═══════════╪═══════╡
1595
+ │ user.id │ 1 │
1596
+ │ user.name │ toto │
1597
+ │ project │ blash │
1598
+ ╰───────────┴───────╯
1599
+ ```
1545
1600
 
1546
- #### Verbosity of output
1601
+ #### Option: `display`: Verbosity of output
1547
1602
 
1548
1603
  Output messages are categorized in 3 types:
1549
1604
 
@@ -1557,13 +1612,17 @@ The option `display` controls the level of output:
1557
1612
  - `data` display `data` and `error` messages
1558
1613
  - `error` display only error messages.
1559
1614
 
1560
- By default, secrets are removed from output: option `show_secrets` defaults to `no`, unless `display` is `data`, to allows piping results.
1561
- To hide secrets from output, set option `show_secrets` to `no`.
1615
+ #### Option: `show_secrets`: Hide or show secrets in results
1616
+
1617
+ If value is `no` (default), then secrets are redacted from command results.
1618
+
1619
+ If value is `yes`, then secrets shown in clear in results.
1562
1620
 
1563
- #### Option: `fields`: Selection of output object properties
1621
+ If `display` is `data`, secrets are included to allows piping results.
1564
1622
 
1565
- By default, a `table` output format will display one line per entry, and columns for each fields (attributes, properties).
1566
- Depending on the command, columns may include by default all fields, or only some selected fields.
1623
+ #### Option: `fields`: Selection of output object fields
1624
+
1625
+ Depending on the command, results may include by default all fields, or only some selected fields.
1567
1626
  It is possible to define specific columns to be displayed, by setting the `fields` option.
1568
1627
 
1569
1628
  The `fields` option is a list that can be either a comma separated list or an extended value `Array`.
@@ -1572,8 +1631,8 @@ Individual elements of the list can be:
1572
1631
 
1573
1632
  - **property** : add property to the current list
1574
1633
  - `-`**property** : remove property from the current list
1575
- - `DEF` : default list of properties (that's the default, when not set)
1576
- - `ALL` : all properties
1634
+ - `DEF` : default list of fields (that's the default, when not set)
1635
+ - `ALL` : all fields
1577
1636
  - A Ruby `RegEx` : using `@ruby:'/.../'`, or `@re:...` add those matching to the list
1578
1637
 
1579
1638
  Examples:
@@ -1581,13 +1640,13 @@ Examples:
1581
1640
  - `a,b,c` : the list of attributes specified as a comma separated list (overrides the all default)
1582
1641
  - `@json:'["a","b","c"]'` : `Array` extended value: same as above
1583
1642
  - `b,DEF,-a` : default property list, remove `a` and add `b` in first position
1584
- - `@ruby:'/^server/'` : Display all properties whose name begin with `server`
1643
+ - `@ruby:'/^server/'` : Display all fields whose name begin with `server`
1585
1644
 
1586
1645
  #### Option: `select`
1587
1646
 
1588
1647
  Table output (`object_list`) can be filtered using option `select`.
1589
1648
  This option is either a `Hash` or `Proc`.
1590
- The `Proc` takes as argument a line (`Hash`) in the table and is a Ruby lambda expression that returns `true` or `false`.
1649
+ The `Proc` takes as argument a line (`Hash`) in the table and is a Ruby lambda expression that shall returns `true` to select or `false` to remove an entry.
1591
1650
 
1592
1651
  Example:
1593
1652
 
@@ -1616,19 +1675,26 @@ In above example, the same result is obtained with option:
1616
1675
 
1617
1676
  The percent selector allows identification of an entity by another unique identifier other than the native identifier.
1618
1677
 
1619
- When a command is executed on a single entity, the entity is identified by a unique identifier that follows the command:
1620
- e.g. `ascli aoc admin user show 1234` where `1234` is the user's identifier.
1678
+ Syntax: `%<field>:<value>`
1621
1679
 
1622
- Some commands provide the following capability:
1623
- If the entity can also be uniquely identified by a name, then the name can be used instead of the identifier, using the **percent selector**: `ascli aoc admin user show %name:john` where `john` is the user name.
1680
+ When a command is executed on a single entity, the entity is identified by a unique identifier that follows the command.
1681
+ For example, in the following command, `1234` is the user's identifier:
1624
1682
 
1625
- Syntax: `%<field>:<value>`
1683
+ ```bash
1684
+ ascli aoc admin user show 1234
1685
+ ```
1626
1686
 
1627
- > **Note:** The legacy option `id` is deprecated: `--id=1234` (options have a single value and thus do not provide the possibility to identify sub-entities)
1687
+ Some commands provide the following capability:
1688
+ If the entity can also be uniquely identified by a name, then the name can be used instead of the identifier, using the **percent selector**.
1689
+ For example, if the name of the user is `john` and a field for this entity named `name` has a value `john`:
1690
+
1691
+ ```bash
1692
+ ascli aoc admin user show %name:john
1693
+ ```
1628
1694
 
1629
1695
  ### Extended Value Syntax
1630
1696
 
1631
- Most options and arguments are specified by a simple string (e.g. username or url).
1697
+ Most options and arguments are specified by a simple string (e.g. `username` or `url`).
1632
1698
  Sometime it is convenient to read a value from a file: for example read the PEM value of a private key, or a list of files.
1633
1699
  Some options expect a more complex value such as `Hash` or `Array`.
1634
1700
 
@@ -1644,31 +1710,31 @@ Decoders act like a function with its parameter on right hand side and are recog
1644
1710
 
1645
1711
  The following decoders are supported:
1646
1712
 
1647
- | Decoder | Parameter| Returns | Description |
1648
- |----------|----------|---------|-------------|
1649
- | `base64` | String | String | Decode a base64 encoded string |
1650
- | `csvt` | String | Array | Decode a titled CSV value |
1651
- | `env` | String | String | Read from a named env var name, e.g. `--password=@env:MYPASSVAR` |
1652
- | `file` | String | String | Read value from specified file (prefix `~/` is replaced with the users home folder), e.g. `--key=@file:~/.ssh/mykey` |
1653
- | `json` | String | Any | Decode JSON values (convenient to provide complex structures) |
1654
- | `lines` | String | Array | Split a string in multiple lines and return an array |
1655
- | `list` | String | Array | Split a string in multiple items taking first character as separator and return an array |
1656
- | `none` | None | Nil | A null value |
1657
- | `path` | String | String | Performs path expansion on specified path (prefix `~/` is replaced with the users home folder), e.g. `--config-file=@path:~/sample_config.yml` |
1658
- | `preset` | String | Hash | Get whole option preset value by name. Sub-values can also be used using `.` as separator. e.g. `foo.bar` is `conf[foo][bar]` |
1659
- | `extend` | String | String | Evaluates embedded extended value syntax in string |
1660
- | `re` | String | Regexp | Ruby Regular Expression (short for `@ruby:/.../`) |
1661
- | `ruby` | String | Any | Execute specified Ruby code |
1662
- | `secret` | None | String | Ask password interactively (hides input) |
1663
- | `stdin` | None | String | Read from stdin in text mode (no value on right) |
1664
- | `stdbin` | None | String | Read from stdin in binary mode (no value on right) |
1665
- | `uri` | String | String | Read value from specified URL, e.g. `--fpac=@uri:http://serv/f.pac` |
1666
- | `val` | String | String | Prevent decoders on the right to be decoded. e.g. `--key=@val:@file:foo` sets the option `key` to value `@file:foo`. |
1667
- | `yaml` | String | Any | Decode YAML |
1668
- | `zlib` | String | String | Un-compress zlib data |
1713
+ | Decoder | Parameter| Returns | Description |
1714
+ |----------|----------|----------|-------------|
1715
+ | `base64` | `String` | `String` | Decode a base64 encoded string |
1716
+ | `csvt` | `String` | `Array` | Decode a titled CSV value |
1717
+ | `env` | `String` | `String` | Read from a named env var name, e.g. `--password=@env:MYPASSVAR` |
1718
+ | `file` | `String` | `String` | Read value from specified file (prefix `~/` is replaced with the users home folder), e.g. `--key=@file:~/.ssh/mykey` |
1719
+ | `json` | `String` | Any | Decode JSON values (convenient to provide complex structures) |
1720
+ | `lines` | `String` | `Array` | Split a string in multiple lines and return an array |
1721
+ | `list` | `String` | `Array` | Split a string in multiple items taking first character as separator and return an array |
1722
+ | `none` | None | Nil | A null value |
1723
+ | `path` | `String` | `String` | Performs path expansion on specified path (prefix `~/` is replaced with the users home folder), e.g. `--config-file=@path:~/sample_config.yml` |
1724
+ | `preset` | `String` | `Hash` | Get whole option preset value by name. Sub-values can also be used using `.` as separator. e.g. `foo.bar` is `conf[foo][bar]` |
1725
+ | `extend` | `String` | `String` | Evaluates embedded extended value syntax in string |
1726
+ | `re` | `String` | `Regexp` | Ruby Regular Expression (short for `@ruby:/.../`) |
1727
+ | `ruby` | `String` | Any | Execute specified Ruby code |
1728
+ | `secret` | None | `String` | Ask password interactively (hides input) |
1729
+ | `stdin` | None | `String` | Read from stdin in text mode (no value on right) |
1730
+ | `stdbin` | None | `String` | Read from stdin in binary mode (no value on right) |
1731
+ | `uri` | `String` | `String` | Read value from specified URL, e.g. `--fpac=@uri:http://serv/f.pac` |
1732
+ | `val` | `String` | `String` | Prevent decoders on the right to be decoded. e.g. `--key=@val:@file:foo` sets the option `key` to value `@file:foo`. |
1733
+ | `yaml` | `String` | Any | Decode YAML |
1734
+ | `zlib` | `String` | `String` | Un-compress zlib data |
1669
1735
 
1670
1736
  > **Note:** A few commands support a value of type `Proc` (lambda expression).
1671
- For example, the **Extended Value** `@ruby:'->(i){i["attr"]}'` is a lambda expression that returns the value of attribute `attr` of the `Hash` `i`.
1737
+ For example, the **Extended Value** `@ruby:'->(i){i["attr"]}'` is a lambda expression that returns the value for key `attr` of the `Hash` `i`.
1672
1738
 
1673
1739
  To display the result of an extended value, use the `config echo` command.
1674
1740
 
@@ -1726,14 +1792,14 @@ ascli config echo @json:@extend:'{"hello":true,"version":"@preset:config.version
1726
1792
 
1727
1793
  ```output
1728
1794
  +---------+-----------+
1729
- | key | value |
1795
+ | field | value |
1730
1796
  +---------+-----------+
1731
1797
  | hello | true |
1732
1798
  | version | 4.14.0 |
1733
1799
  +---------+-----------+
1734
1800
  ```
1735
1801
 
1736
- Example: Create a `Hash` from YAML provided as **heredoc**:
1802
+ Example: Create a `Hash` from YAML provided as shell **heredoc**:
1737
1803
 
1738
1804
  ```bash
1739
1805
  ascli config echo @yaml:@stdin: --format=json<<EOF
@@ -1753,7 +1819,7 @@ EOF
1753
1819
 
1754
1820
  ### Configuration and Persistency Folder
1755
1821
 
1756
- `ascli` configuration and other runtime files (token cache, file lists, persistency files, SDK) are stored by default in `[User's home folder]/.aspera/ascli`.
1822
+ `ascli` configuration and persistency files (token cache, file lists, persistency files) are stored by default in `[User's home folder]/.aspera/ascli`.
1757
1823
 
1758
1824
  > **Note:** `[User's home folder]` is found using Ruby's `Dir.home` (`rb_w32_home_dir`).
1759
1825
  It uses the `HOME` env var primarily, and on MS Windows it also looks at `%HOMEDRIVE%%HOMEPATH%` and `%USERPROFILE%`.
@@ -1782,9 +1848,9 @@ ascli config folder
1782
1848
  C:\Users\Kenji\.aspera\ascli
1783
1849
  ```
1784
1850
 
1785
- When OAuth is used (AoC, Faspex4 api v4, Faspex5) `ascli` keeps a cache of generated bearer tokens in folder `persist_store` in configuration folder by default.
1851
+ When OAuth is used (AoC, Faspex5) `ascli` keeps a cache of generated bearer tokens in folder `persist_store` in configuration folder by default.
1786
1852
  Option `cache_tokens` (**yes**/no) allows to control if Oauth tokens are cached on file system, or generated for each request.
1787
- The command `config flush_tokens` clears that cache.
1853
+ The command `config tokens flush` clears that cache.
1788
1854
  Tokens are kept on disk for a maximum of 30 minutes (`TOKEN_CACHE_EXPIRY_SEC`) and garbage collected after that.
1789
1855
  When a token has expired, then a new token is generated, either using a refresh_token if it is available, or by the default method.
1790
1856
 
@@ -1958,7 +2024,6 @@ ascp products list
1958
2024
  ascp products use 'IBM Aspera Connect'
1959
2025
  ascp show
1960
2026
  ascp spec
1961
- ascp use /usr/bin/ascp
1962
2027
  check_update
1963
2028
  coffee
1964
2029
  coffee --ui=text
@@ -1977,6 +2042,8 @@ echo -- --special-string
1977
2042
  echo @base64:SGVsbG8gV29ybGQK
1978
2043
  echo @csvt:@stdin:
1979
2044
  echo @env:USER
2045
+ echo @json:'[{"user":{"id":1,"name":"foo"},"project":"bar"}]' --multi-single=single
2046
+ echo @json:'[{"user":{"id":1,"name":"foo"},"project":"bar"}]' --multi-single=yes
1980
2047
  echo @lines:@stdin:
1981
2048
  echo @list:,1,2,3
1982
2049
  echo @secret:
@@ -1990,7 +2057,6 @@ echo hello
1990
2057
  email_test --notify-to=my_email_external
1991
2058
  file
1992
2059
  file --logger=syslog --log-level=debug
1993
- flush_tokens
1994
2060
  folder
1995
2061
  gem name
1996
2062
  gem path
@@ -2006,6 +2072,7 @@ preset delete conf_name
2006
2072
  preset initialize conf_name @json:'{"p1":"v1","p2":"v2"}'
2007
2073
  preset list
2008
2074
  preset overview
2075
+ preset set GLOBAL version_check_days 0
2009
2076
  preset set conf_name param value
2010
2077
  preset set default shares conf_name
2011
2078
  preset show conf_name
@@ -2017,6 +2084,7 @@ remote_certificate chain https://node.example.com/path
2017
2084
  remote_certificate name https://node.example.com/path
2018
2085
  remote_certificate only https://node.example.com/path
2019
2086
  smtp_settings
2087
+ tokens flush
2020
2088
  vault create my_label @json:'{"password":"my_password_here","description":"my secret"}'
2021
2089
  vault delete my_label
2022
2090
  vault info
@@ -2397,10 +2465,10 @@ The following options can be specified in the option `image`:
2397
2465
 
2398
2466
  | Option | Type | Description |
2399
2467
  |------------|---------|-------------|
2400
- | reserve | Integer | Lines reserved to display a status |
2401
- | text | Bool | Display text instead of image|
2402
- | double | Bool | Display double text resolution (half characters) |
2403
- | font_ratio | Float | Font height/width ratio in terminal |
2468
+ | reserve | `Integer` | Lines reserved to display a status |
2469
+ | text | `Bool` | Display text instead of image|
2470
+ | double | `Bool` | Display double text resolution (half characters) |
2471
+ | font_ratio | `Float` | Font height/width ratio in terminal |
2404
2472
 
2405
2473
  ```bash
2406
2474
  ascli config image https://eudemo.asperademo.com/wallpaper.jpg --ui=text --image=@json:'{"text":true}'
@@ -2433,12 +2501,12 @@ The gem is equipped with traces, mainly for debugging and learning APIs.
2433
2501
  By default logging level is `warn` and the output channel is `stderr`.
2434
2502
  To increase debug level, use option `log_level` (e.g. using command line `--log-level=xx`, env var `ASCLI_LOG_LEVEL`, or an [Option Preset](#option-preset)).
2435
2503
 
2436
- By default passwords and secrets are removed from logs.
2437
- Use option `log_secrets` set to `yes` to reveal secrets in logs.
2504
+ By default passwords and secrets are redacted from logs.
2505
+ Set option `log_secrets` to `yes` to include secrets in logs.
2438
2506
 
2439
- Available loggers: `stdout`, `stderr`, `syslog`.
2507
+ Option `logger`: `stdout`, `stderr`, `syslog`.
2440
2508
 
2441
- Available levels: `debug`, `info`, `warn`, `error`.
2509
+ Option `log_level`: `debug`, `info`, `warn`, `error`.
2442
2510
 
2443
2511
  > **Note:** When using the `direct` agent (`ascp`), additional transfer logs can be activated using `ascp` options and `ascp_args`, see [`direct`](#agent-direct).
2444
2512
 
@@ -2491,7 +2559,7 @@ HTTP connection parameters (not `ascp` wss) can be adjusted using option `http_o
2491
2559
  | `retry_on_error` | 0 | `ascli` |
2492
2560
  | `retry_sleep` | nil | `ascli` |
2493
2561
 
2494
- Time values are in set **seconds** and can be of type either integer or float.
2562
+ Time values are in set **seconds** and can be of type either `Integer` or `Float`.
2495
2563
  Default values are the ones of Ruby:
2496
2564
  For a full list, refer to the Ruby library: [`Net::HTTP`](https://ruby-doc.org/stdlib/libdoc/net/http/rdoc/Net/HTTP.html).
2497
2565
 
@@ -2645,7 +2713,7 @@ ascli config ascp info
2645
2713
 
2646
2714
  ```output
2647
2715
  +--------------------+-----------------------------------------------------------+
2648
- | key | value |
2716
+ | field | value |
2649
2717
  +--------------------+-----------------------------------------------------------+
2650
2718
  | ascp | /Users/laurent/.aspera/ascli/sdk/ascp |
2651
2719
  ...
@@ -2794,19 +2862,19 @@ The `transfer_info` option accepts the following optional parameters to control
2794
2862
 
2795
2863
  | Name | Type | Description |
2796
2864
  |------------------------|---------|-------------|
2797
- | `wss` | Bool | Web Socket Session<br/>Enable use of web socket session in case it is available<br/>Default: true |
2798
- | `quiet` | Bool | If `true`, then `ascp` progress bar is not shown.<br/>Default: `false` |
2799
- | `trusted_certs` | Array | List of repositories for trusted certificates. |
2800
- | `client_ssh_key` | String | SSH Keys to use for token-based transfers. One of: `dsa_rsa`, `rsa`, `per_client`. Default: `rsa` |
2801
- | `ascp_args` | Array | Array of strings with native `ascp` arguments.<br/>Default: `[]` |
2802
- | `spawn_timeout_sec` | Float | Multi session<br/>Verification time that `ascp` is running<br/>Default: `3` |
2803
- | `spawn_delay_sec` | Float | Multi session<br/>Delay between startup of sessions<br/>Default: `2` |
2804
- | `multi_incr_udp` | Bool | Multi Session<br/>Increment UDP port on multi-session<br/>If `true`, each session will have a different UDP port starting at `fasp_port` (or default 33001)<br/>Else, each session will use `fasp_port` (or `ascp` default)<br/>Default: `true` on Windows, else `false` |
2805
- | `resume` | Hash | Resume parameters. See below |
2806
- | `resume.iter_max` | Integer | Max number of retry on error<br/>Default: `7` |
2807
- | `resume.sleep_initial` | Integer | First Sleep before retry<br/>Default: `2` |
2808
- | `resume.sleep_factor` | Integer | Multiplier of sleep period between attempts<br/>Default: `2` |
2809
- | `resume.sleep_max` | Integer | Default: `60` |
2865
+ | `wss` | `Bool` | Web Socket Session<br/>Enable use of web socket session in case it is available<br/>Default: true |
2866
+ | `quiet` | `Bool` | If `true`, then `ascp` progress bar is not shown.<br/>Default: `false` |
2867
+ | `trusted_certs` | `Array` | List of repositories for trusted certificates. |
2868
+ | `client_ssh_key` | `String` | SSH Keys to use for token-based transfers. One of: `dsa_rsa`, `rsa`, `per_client`. Default: `rsa` |
2869
+ | `ascp_args` | `Array` | Array of strings with native `ascp` arguments.<br/>Default: `[]` |
2870
+ | `spawn_timeout_sec` | `Float` | Multi session<br/>Verification time that `ascp` is running<br/>Default: `3` |
2871
+ | `spawn_delay_sec` | `Float` | Multi session<br/>Delay between startup of sessions<br/>Default: `2` |
2872
+ | `multi_incr_udp` | `Bool` | Multi Session<br/>Increment UDP port on multi-session<br/>If `true`, each session will have a different UDP port starting at `fasp_port` (or default 33001)<br/>Else, each session will use `fasp_port` (or `ascp` default)<br/>Default: `true` on Windows, else `false` |
2873
+ | `resume` | `Hash` | Resume parameters. See below |
2874
+ | `resume.iter_max` | `Integer` | Max number of retry on error<br/>Default: `7` |
2875
+ | `resume.sleep_initial` | `Integer` | First Sleep before retry<br/>Default: `2` |
2876
+ | `resume.sleep_factor` | `Integer` | Multiplier of sleep period between attempts<br/>Default: `2` |
2877
+ | `resume.sleep_max` | `Integer` | Default: `60` |
2810
2878
 
2811
2879
  In case of transfer interruption, the agent will **resume** a transfer up to `iter_max` time.
2812
2880
  Sleep between iterations is given by the following formula where `iter_index` is the current iteration index, starting at 0:
@@ -2938,12 +3006,12 @@ This is especially useful for direct node-to-node transfers.
2938
3006
 
2939
3007
  Parameters provided in option `transfer_info` are:
2940
3008
 
2941
- | Name | Type | Description |
2942
- |----------|--------|-------------|
2943
- | url | string | URL of the node API</br>Mandatory |
2944
- | username | string | Node api user or access key</br>Mandatory |
2945
- | password | string | Password, secret or bearer token</br>Mandatory |
2946
- | root_id | string | Root file id</br>Mandatory only for bearer token |
3009
+ | Nam e | Type | Description |
3010
+ |------------|--------|--------------------------------------------------|
3011
+ | `url` | `String` | URL of the node API</br>Mandatory |
3012
+ | `username` | `String` | Node api user or access key</br>Mandatory |
3013
+ | `password` | `String` | Password, secret or bearer token</br>Mandatory |
3014
+ | `root_id` | `String` | Root file id</br>Mandatory only for bearer token |
2947
3015
 
2948
3016
  Like any other option, `transfer_info` can get its value from a pre-configured [Option Preset](#option-preset) :
2949
3017
 
@@ -2972,10 +3040,10 @@ Parameters provided in option `transfer_info` are:
2972
3040
 
2973
3041
  | Name | Type | Description |
2974
3042
  |------------------------|--------|---------------------------------------|
2975
- | url | string | URL of the HTTP GW</br>Mandatory |
2976
- | upload_chunk_size | int | Size in bytes of chunks for upload<br/>Default: `64000` |
2977
- | api_version | string | Force use of version (`v1`, `v2`)<br/>Default: `v2` |
2978
- | synchronous | bool | Wait for each message acknowledgment<br/>Default: `false` |
3043
+ | url | `String` | URL of the HTTP GW</br>Mandatory |
3044
+ | upload_chunk_size | `Integer` | Size in bytes of chunks for upload<br/>Default: `64000` |
3045
+ | api_version | `String` | Force use of version (`v1`, `v2`)<br/>Default: `v2` |
3046
+ | synchronous | `Bool` | Wait for each message acknowledgment<br/>Default: `false` |
2979
3047
 
2980
3048
  Example:
2981
3049
 
@@ -2996,9 +3064,9 @@ Options for `transfer_info` are:
2996
3064
 
2997
3065
  | Name | Type | Description |
2998
3066
  |----------|--------|-------------|
2999
- | `url` | string | IP address and port listened by the daemon</br>Mandatory<br/>Default: `:0` |
3000
- | `external` | bool | Use external daemon, do not start one.<br/>Default: `false` |
3001
- | `keep` | bool | Keep the daemon running after exiting `ascli`<br/>Default: `false` |
3067
+ | `url` | `String` | IP address and port listened by the daemon</br>Mandatory<br/>Default: `:0` |
3068
+ | `external` | `Bool` | Use external daemon, do not start one.<br/>Default: `false` |
3069
+ | `keep` | `Bool` | Keep the daemon running after exiting `ascli`<br/>Default: `false` |
3002
3070
 
3003
3071
  > **Note:** If port zero is specified in the URL, then the daemon will listen on a random available port. If no address is specified, then `127.0.0.1` is used.
3004
3072
 
@@ -3098,8 +3166,8 @@ Columns:
3098
3166
  | destination_root_id | string | &nbsp; | &nbsp; | &nbsp; | &nbsp; | &nbsp; | The file ID of the destination root directory.<br/>Required when using Bearer token auth for the destination node.<br/>(&lt;ignored&gt;) |
3099
3167
  | dgram_size | int | Y | Y | Y | Y | Y | UDP datagram size in bytes<br/>(-Z {int}) |
3100
3168
  | direction | string | Y | Y | Y | Y | Y | Direction of transfer (on client side)<br/>Allowed values: send, receive<br/>(--mode (conversion){enum}) |
3101
- | exclude_newer_than | int | Y | &nbsp; | &nbsp; | &nbsp; | &nbsp; | skip src files with mtime > arg<br/>(--exclude-newer-than {int}) |
3102
- | exclude_older_than | int | Y | &nbsp; | &nbsp; | &nbsp; | &nbsp; | skip src files with mtime < arg<br/>(--exclude-older-than {int}) |
3169
+ | exclude_newer_than | string | Y | Y | Y | Y | Y | Exclude files, but not directories, from the transfer if they are newer than the specified number of seconds added to the source computer's epoch. e.g. "-86400" for newer than a day back.<br/>(--exclude-newer-than {string}) |
3170
+ | exclude_older_than | string | Y | Y | Y | Y | Y | Exclude files, but not directories, from the transfer if they are older than the specified number of seconds added to the source computer's epoch. e.g. "-86400" for older than a day back.<br/>(--exclude-older-than {string}) |
3103
3171
  | fasp_port | int | Y | Y | Y | Y | Y | Specifies fasp (UDP) port.<br/>(-O {int}) |
3104
3172
  | fasp_url | string | &nbsp; | &nbsp; | &nbsp; | &nbsp; | &nbsp; | Only used in Faspex.<br/>(&lt;ignored&gt;) |
3105
3173
  | file_checksum | string | Y | Y | &nbsp; | &nbsp; | &nbsp; | Enable checksum reporting for transferred files by specifying the hash to use.<br/>Allowed values: sha-512, sha-384, sha-256, sha1, md5, none<br/>(&lt;ignored&gt;) |
@@ -3155,7 +3223,7 @@ Columns:
3155
3223
  | ssh_private_key_passphrase | string | Y | &nbsp; | &nbsp; | &nbsp; | &nbsp; | The passphrase associated with the transfer user's SSH private key. Available as of 3.7.2.<br/>(env:ASPERA_SCP_PASS) |
3156
3224
  | sshfp | string | Y | Y | Y | Y | Y | Check it against server SSH host key fingerprint<br/>(--check-sshfp {string}) |
3157
3225
  | symlink_policy | string | Y | Y | Y | Y | Y | Handle source side symbolic links<br/>Allowed values: follow, copy, copy+force, skip<br/>(--symbolic-links {enum}) |
3158
- | tags | hash | Y | Y | Y | Y | Y | Metadata for transfer as JSON<br/>(--tags64 (conversion){hash}) |
3226
+ | tags | hash | Y | Y | Y | Y | Y | Metadata for transfer as JSON. Key `aspera` is reserved. Key `aspera.xfer_retry` specified a retry timeout for node api initiated transfers.<br/>(--tags64 (conversion){hash}) |
3159
3227
  | target_rate_cap_kbps | int | &nbsp; | &nbsp; | Y | &nbsp; | &nbsp; | Returned by upload/download_setup node API.<br/>(&lt;ignored&gt;) |
3160
3228
  | target_rate_kbps | int | Y | Y | Y | Y | Y | Specifies desired speed for the transfer.<br/>(-l {int}) |
3161
3229
  | target_rate_percentage | string | Y | Y | Y | Y | Y | TODO: remove ?<br/>(&lt;ignored&gt;) |
@@ -3166,6 +3234,7 @@ Columns:
3166
3234
  | write_threads | int | &nbsp; | &nbsp; | &nbsp; | &nbsp; | &nbsp; | ascp4 only<br/>(&lt;ignored&gt;) |
3167
3235
  | wss_enabled | bool | Y | Y | Y | Y | Y | Server has Web Socket service enabled<br/>(&lt;special&gt;) |
3168
3236
  | wss_port | int | Y | Y | Y | Y | Y | TCP port used for websocket service feed<br/>(&lt;special&gt;) |
3237
+ | xfer_max_retries | int | &nbsp; | Y | &nbsp; | &nbsp; | &nbsp; | maximum number of retries, for node API initiated transfers. Shall not exceed aspera.conf `transfer_manager_max_retries` (default 5).<br/>(&lt;ignored&gt;) |
3169
3238
 
3170
3239
  #### Destination folder for transfers
3171
3240
 
@@ -3610,7 +3679,7 @@ ascli server upload "faux:///mydir?file=testfile&count=1m&size=0&inc=2&seq=seque
3610
3679
  ```text
3611
3680
  ascli -h
3612
3681
  NAME
3613
- ascli -- a command line tool for Aspera Applications (v4.20.0)
3682
+ ascli -- a command line tool for Aspera Applications (v4.21.0)
3614
3683
 
3615
3684
  SYNOPSIS
3616
3685
  ascli COMMANDS [OPTIONS] [ARGS]
@@ -3649,8 +3718,7 @@ OPTIONS: global
3649
3718
  --select=VALUE Select only some items in lists: column, value (Hash, Proc)
3650
3719
  --table-style=VALUE Table display style (Hash)
3651
3720
  --flat-hash=ENUM (Table) Display deep values as additional keys: no, [yes]
3652
- --transpose-single=ENUM (Table) Single object fields output vertically: no, [yes]
3653
- --multi-table=ENUM (Table) Each element of a table are displayed as a table: [no], yes
3721
+ --multi-single=ENUM (Table) Control how object list is displayed as single table, or multiple objects: [no], yes, single
3654
3722
  --show-secrets=ENUM Show secrets on command output: [no], yes
3655
3723
  --image=VALUE Options for image display (Hash)
3656
3724
  -h, --help Show this message
@@ -3707,7 +3775,7 @@ OPTIONS: global
3707
3775
  --transfer-info=VALUE Parameters for transfer agent (Hash)
3708
3776
 
3709
3777
  COMMAND: config
3710
- SUBCOMMANDS: ascp check_update coffee detect documentation echo email_test file flush_tokens folder gem genkey image initdemo open platform plugins preset proxy_check pubkey remote_certificate smtp_settings test vault wizard
3778
+ SUBCOMMANDS: ascp check_update coffee detect documentation echo email_test file folder gem genkey image initdemo open platform plugins preset proxy_check pubkey remote_certificate smtp_settings test tokens vault wizard
3711
3779
 
3712
3780
 
3713
3781
  COMMAND: shares
@@ -4781,7 +4849,7 @@ So, for example, the creation of a node using ATS in IBM Cloud looks like (see o
4781
4849
  First, Retrieve the ATS node address
4782
4850
 
4783
4851
  ```bash
4784
- ascli aoc admin ats cluster show --cloud=softlayer --region=eu-de --fields=transfer_setup_url --format=csv --transpose-single=no
4852
+ ascli aoc admin ats cluster show --cloud=softlayer --region=eu-de --fields=transfer_setup_url --format=csv
4785
4853
  ```
4786
4854
 
4787
4855
  Then use the returned address for the `url` key to actually create the AoC Node entity:
@@ -4845,6 +4913,20 @@ If a user recipient (email) is not already registered and the workspace allows e
4845
4913
  - if the option `new_user_option` is `@json:{"package_contact":true}` (default), then a public link is sent and the external user does not need to create an account
4846
4914
  - if the option `new_user_option` is `@json:{}`, then external users are invited to join the workspace
4847
4915
 
4916
+ #### List packages
4917
+
4918
+ By default, when using `aoc packages list`, the following `query` is performed:
4919
+
4920
+ | query parameter | value |
4921
+ |----------------------------|-------|
4922
+ | `archived` | `false` |
4923
+ | `has_content` | `true` |
4924
+ | `received` | `true` |
4925
+ | `completed` | `true` |
4926
+ | `workspace_id` | based on current workspace |
4927
+ | `exclude_dropbox_packages` | `true` or `false` depending if watching a dropbox|
4928
+ | `dropbox_id` | set accoring to `dropbox_name` |
4929
+
4848
4930
  #### Example: Send a package with one file to two users, using their email
4849
4931
 
4850
4932
  ```bash
@@ -4886,7 +4968,7 @@ ascli aoc packages list --query=@json:'{"dropbox_name":"My Shared Inbox","archiv
4886
4968
  Using shared inbox identifier: first retrieve the id of the shared inbox, and then list packages with the appropriate filter.
4887
4969
 
4888
4970
  ```bash
4889
- shared_box_id=$(ascli aoc packages shared_inboxes show --name='My Shared Inbox' --format=csv --display=data --fields=id --transpose-single=no)
4971
+ shared_box_id=$(ascli aoc packages shared_inboxes show --name='My Shared Inbox' --format=csv --display=data --fields=id)
4890
4972
  ```
4891
4973
 
4892
4974
  ```bash
@@ -4938,6 +5020,26 @@ ascli aoc packages recv ALL --once-only=yes --lock-port=12345
4938
5020
 
4939
5021
  Typically, one would execute this command on a regular basis, using the method of your choice: see [Scheduler](#scheduler).
4940
5022
 
5023
+ ### Example: Content of a received Package
5024
+
5025
+ Some `node` operations are available for a package, such as `browse` and `find`.
5026
+
5027
+ To list the content of a package, use command `packages browse <package id> <folder>`:
5028
+
5029
+ ```bash
5030
+ ascli aoc package browse my5CnbeWng /
5031
+ ```
5032
+
5033
+ To list recursively, use command `find`.
5034
+
5035
+ To download only some of the files listed in the package, just add the path of the files on the command line.
5036
+
5037
+ For advanced users, it's also possible to pipe node information for the package and use node operations:
5038
+
5039
+ ```bash
5040
+ ascli aoc package node_info <package id here> / --format=json --show-secrets=yes --display=data | ascli node -N --preset=@json:@stdin: access_key do self browse /
5041
+ ```
5042
+
4941
5043
  ### Files
4942
5044
 
4943
5045
  The Files application presents a **Home** folder to users in a given workspace.
@@ -5092,7 +5194,7 @@ For instructions, refer to section `find` for plugin `node`.
5092
5194
 
5093
5195
  ```bash
5094
5196
  admin analytics transfers nodes
5095
- admin analytics transfers organization --query=@json:'{"status":"completed","direction":"receive"}' --notify-to=my_email_external --notify-template=@ruby:'%Q{From: <%=from_name%> <<%=from_email%>>\nTo: <<%=to%>>\nSubject: <%=ev["files_completed"]%> files received\n\n<%=ev.to_yaml%>}'
5197
+ admin analytics transfers organization --query=@json:'{"status":"completed","direction":"receive","limit":2}' --notify-to=my_email_external --notify-template=@ruby:'%Q{From: <%=from_name%> <<%=from_email%>>\nTo: <<%=to%>>\nSubject: <%=ev["files_completed"]%> files received\n\n<%=ev.to_yaml%>}'
5096
5198
  admin analytics transfers users --once-only=yes
5097
5199
  admin application list
5098
5200
  admin ats access_key create --cloud=aws --region=my_region --params=@json:'{"id":"ak_aws","name":"my test key AWS","storage":{"type":"aws_s3","bucket":"my_bucket","credentials":{"access_key_id":"my_access_key","secret_access_key":"my_secret_key"},"path":"/"}}'
@@ -5117,8 +5219,10 @@ admin group list
5117
5219
  admin kms_profile list
5118
5220
  admin node do %name:my_node_name --secret=my_ak_secret browse /
5119
5221
  admin node do %name:my_node_name --secret=my_ak_secret delete /folder1
5222
+ admin node do %name:my_node_name --secret=my_ak_secret delete /folder_sub
5120
5223
  admin node do %name:my_node_name --secret=my_ak_secret mkdir /folder1
5121
- admin node do %name:my_node_name --secret=my_ak_secret v3 access_key create @json:'{"id":"testsub1","storage":{"path":"/folder1"}}'
5224
+ admin node do %name:my_node_name --secret=my_ak_secret mkdir /folder_sub
5225
+ admin node do %name:my_node_name --secret=my_ak_secret v3 access_key create @json:'{"id":"testsub1","storage":{"path":"/folder_sub"}}'
5122
5226
  admin node do %name:my_node_name --secret=my_ak_secret v3 access_key delete testsub1
5123
5227
  admin node do %name:my_node_name --secret=my_ak_secret v3 events
5124
5228
  admin node do %name:my_node_name delete test_shared_folder
@@ -5189,13 +5293,14 @@ files v3 info
5189
5293
  gateway --pid-file=pid_aocfxgw https://localhost:12345/aspera/faspex &
5190
5294
  org --url=my_public_link_recv_from_aoc_user
5191
5295
  organization
5192
- packages browse package_id3 /contents
5296
+ packages browse package_id3 /
5193
5297
  packages list
5194
5298
  packages list --query=@json:'{"dropbox_name":"my_shared_inbox_name","sort":"-received_at","archived":false,"received":true,"has_content":true,"exclude_dropbox_packages":false}'
5195
5299
  packages receive ALL --once-only=yes --to-folder=. --lock-port=12345
5196
5300
  packages receive ALL --once-only=yes --to-folder=. --lock-port=12345 --query=@json:'{"dropbox_name":"my_shared_inbox_name","archived":false,"received":true,"has_content":true,"exclude_dropbox_packages":false,"include_draft":false}' --ts=@json:'{"resume_policy":"sparse_csum","target_rate_kbps":50000}'
5197
5301
  packages receive INIT --once-only=yes --query=@json:'{"dropbox_name":"my_shared_inbox_name"}'
5198
5302
  packages receive package_id3 --to-folder=.
5303
+ packages receive package_id3 --to-folder=. /
5199
5304
  packages send --workspace=my_workspace_shared_inbox --validate-metadata=yes @json:'{"name":"$(notdir test) PACKAGE_TITLE_BASE","recipients":["my_shared_inbox_meta"],"metadata":[{"input_type":"single-text","name":"Project Id","values":["123"]},{"input_type":"single-dropdown","name":"Type","values":["Opt2"]},{"input_type":"multiple-checkbox","name":"CheckThose","values":["Check1","Check2"]},{"input_type":"date","name":"Optional Date","values":["2021-01-13T15:02:00.000Z"]}]}' test_file.bin
5200
5305
  packages send --workspace=my_workspace_shared_inbox --validate-metadata=yes @json:'{"name":"$(notdir test) PACKAGE_TITLE_BASE","recipients":["my_shared_inbox_meta"],"metadata":{"Project Id":"456","Type":"Opt2","CheckThose":["Check1","Check2"],"Optional Date":"2021-01-13T15:02:00.000Z"}}' test_file.bin
5201
5306
  packages send --workspace=my_workspace_shared_inbox --validate-metadata=yes @json:'{"name":"$(notdir test) PACKAGE_TITLE_BASE","recipients":["my_shared_inbox_meta"],"metadata":{"Type":"Opt2","CheckThose":["Check1","Check2"],"Optional Date":"2021-01-13T15:02:00.000Z"}}' test_file.bin
@@ -5290,7 +5395,7 @@ ascli ats api_key create
5290
5395
 
5291
5396
  ```output
5292
5397
  +--------+----------------------------------------------+
5293
- | key | value |
5398
+ | field | value |
5294
5399
  +--------+----------------------------------------------+
5295
5400
  | id | ats_XXXXXXXXXXXXXXXXXXXXXXXX |
5296
5401
  | secret | YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY |
@@ -5392,7 +5497,7 @@ delete my_inside_folder
5392
5497
  delete my_upload_folder/to.delete
5393
5498
  df
5394
5499
  download my_inside_folder/test_file.bin --to-folder=. --transfer-info=@json:'{"wss":false,"resume":{"iter_max":1}}'
5395
- download my_inside_folder/test_file.bin --to-folder=my_upload_folder --transfer=node
5500
+ download my_large_file --to-folder=my_upload_folder --transfer=node --ts=@json:'{"resume_policy":"none"}'
5396
5501
  du /
5397
5502
  health transfer --to-folder=my_upload_folder --format=nagios
5398
5503
  info
@@ -5413,7 +5518,7 @@ upload --sources=@ts --transfer-info=@json:'{"ascp_args":["--file-pair-list","fi
5413
5518
  upload --sources=@ts --ts=@json:'{"paths":[{"source":"test_file.bin","destination":"my_inside_folder/other_name_4"}]}' --transfer=trsdk
5414
5519
  upload --src-type=pair 'test_file.bin' my_inside_folder/other_name_2 --notify-to=my_email_external --transfer-info=@json:'{"ascp_args":["-l","100m"]}'
5415
5520
  upload --src-type=pair --sources=@json:'["test_file.bin","my_inside_folder/other_name_3"]' --transfer-info=@json:'{"quiet":false}' --ts=@json:'{"use_ascp4":true}' --progress=no
5416
- upload --src-type=pair test_file.bin my_upload_folder/other_name_5 --ts=@json:'{"cipher":"aes-192-gcm","content_protection":"encrypt","content_protection_password":"my_secret_here","cookie":"biscuit","create_dir":true,"delete_before_transfer":false,"delete_source":false,"exclude_newer_than":1,"exclude_older_than":10000,"fasp_port":33001,"http_fallback":false,"multi_session":0,"overwrite":"diff+older","precalculate_job_size":true,"preserve_access_time":true,"preserve_creation_time":true,"rate_policy":"fair","resume_policy":"sparse_csum","symlink_policy":"follow"}'
5521
+ upload --src-type=pair test_file.bin my_upload_folder/other_name_5 --ts=@json:'{"cipher":"aes-192-gcm","content_protection":"encrypt","content_protection_password":"my_secret_here","cookie":"biscuit","create_dir":true,"delete_before_transfer":false,"delete_source":false,"exclude_newer_than":"-1","exclude_older_than":"-10000","fasp_port":33001,"http_fallback":false,"multi_session":0,"overwrite":"diff+older","precalculate_job_size":true,"preserve_access_time":true,"preserve_creation_time":true,"rate_policy":"fair","resume_policy":"sparse_csum","symlink_policy":"follow"}'
5417
5522
  upload --to-folder=my_upload_folder/target_hot --lock-port=12345 --transfer-info=@json:'{"ascp_args":["--remove-after-transfer","--remove-empty-directories","--exclude-newer-than=-8","--src-base","source_hot"]}' source_hot
5418
5523
  ```
5419
5524
 
@@ -5523,6 +5628,8 @@ This plugin gives access to capabilities provided by the HSTS node API.
5523
5628
  The authentication is `username` and `password` or `access_key` and `secret` through options: `username` and `password`.
5524
5629
 
5525
5630
  > **Note:** Capabilities of this plugin are used in other plugins which access to the node API, such as `aoc`, `ats`, `shares`.
5631
+ >
5632
+ > **Note:** This plugin can be used with any type of **Aspera Node**, either on-prem or ATS, provided that you have node api credentials. Those credentials can be either Node API user or Access Key (e.g. on ATS).
5526
5633
 
5527
5634
  ### File Operations
5528
5635
 
@@ -5792,7 +5899,7 @@ Bearer tokens are part of the **gen4/access key** API.
5792
5899
  It follows the model of OAuth 2.
5793
5900
  For example, they are used in Aspera on Cloud.
5794
5901
  This is also available for developers for any application integrating Aspera.
5795
- In this API, files, users and groups are identified by an id (a String, e.g. `"125"`, not necessarily numerical).
5902
+ In this API, files, users and groups are identified by an id (a `String`, e.g. `"125"`, not necessarily numerical).
5796
5903
 
5797
5904
  Bearer tokens are typically generated by the authentication application and then recognized by the node API.
5798
5905
  A bearer token is authorized on the node by creating `permissions` on a **folder**.
@@ -5923,7 +6030,6 @@ access_key do my_ak_name delete test_nd_ak3
5923
6030
  access_key do my_ak_name download test_nd_ak3 --to-folder=.
5924
6031
  access_key do my_ak_name find my_test_folder
5925
6032
  access_key do my_ak_name find my_test_folder @ruby:'->(f){f["name"].end_with?(".jpg")}'
5926
- access_key do my_ak_name find my_test_folder exec:'f["name"].end_with?(".jpg")'
5927
6033
  access_key do my_ak_name mkdir /tst_nd_ak
5928
6034
  access_key do my_ak_name node_info /
5929
6035
  access_key do my_ak_name rename /tst_nd_ak test_nd_ak2
@@ -6152,7 +6258,7 @@ admin contacts list
6152
6258
  admin distribution_lists create @json:'{"name":"test4","contacts":[{"name":"john@example.com"}]}'
6153
6259
  admin distribution_lists delete %name:test4
6154
6260
  admin distribution_lists list --query=@json:'{"type":"global"}'
6155
- admin event app
6261
+ admin event app --query=@json:'{"max":20}'
6156
6262
  admin event web
6157
6263
  admin jobs list --query=@json:'{"job_type":"email","status":"failed"}' --fields=id,error_desc
6158
6264
  admin metadata_profiles list
@@ -6320,7 +6426,7 @@ To list the content of a package, use command `faspex5 packages browse /`.
6320
6426
 
6321
6427
  Option `query` is available.
6322
6428
 
6323
- To list recursively add option `--query=@json:{"recursive":true}`.
6429
+ To list recursively add option `--query=@json:'{"recursive":true}'`.
6324
6430
 
6325
6431
  > **Note:** Option `recursive` makes recursive API calls, so it can take a long time on large packages.
6326
6432
 
@@ -6393,15 +6499,15 @@ ascli faspex5 admin shared create @json:'{"name":"the shared inbox","metadata_pr
6393
6499
  ### Faspex 5: List content in Shared folder and send package from remote source
6394
6500
 
6395
6501
  ```bash
6396
- ascli faspex5 shared_folders list
6502
+ ascli faspex5 shared_folders list --fields=id,name
6397
6503
  ```
6398
6504
 
6399
6505
  ```markdown
6400
- +----+----------+---------+-----+
6401
- | id | name | node_id | ... |
6402
- +----+----------+---------+-----+
6403
- | 3 | partages | 2 | ... |
6404
- +----+----------+---------+-----+
6506
+ +----+----------+
6507
+ | id | name |
6508
+ +----+----------+
6509
+ | 3 | partages |
6510
+ +----+----------+
6405
6511
  ```
6406
6512
 
6407
6513
  ```bash
@@ -6471,6 +6577,22 @@ ascli faspex5 packages list --box=ALL --format=yaml --fields=id | ascli faspex5
6471
6577
  > **Note:** Above command will mark all packages for deletion, and will be permanently removed after the configured period (`clean_deleted` command).
6472
6578
  > It is possible to add a filter to the list command to only delete packages matching some criteria, e.g. using `--select=@ruby:`.
6473
6579
 
6580
+ ### Faspex 5: Admin: Unlock user
6581
+
6582
+ To unlock a user, you can de-activate and then re-activate the user:
6583
+
6584
+ ```bash
6585
+ ascli faspex5 admin accounts modify %name:some.user@example.com @json:'{"account_activated":false}'
6586
+ ```
6587
+
6588
+ ```bash
6589
+ ascli faspex5 admin accounts modify %name:some.user@example.com @json:'{"account_activated":true}'
6590
+ ```
6591
+
6592
+ > **Note:** here we use the convenient percent selector, but the numerical if can be used as well.
6593
+
6594
+ To send a password reset link to a user, use command `reset_password` on the `account`.
6595
+
6474
6596
  ### Faspex 5: Faspex 4-style postprocessing
6475
6597
 
6476
6598
  `ascli` provides command `postprocessing` in plugin `faspex5` to emulate Faspex 4 postprocessing.
@@ -6486,15 +6608,15 @@ The following parameters are supported:
6486
6608
 
6487
6609
  | parameter | type | default | description |
6488
6610
  |----------------------------|---------|------------------------|-----------------------------------------------------|
6489
- | url | string | http://localhost:8080 | Base url on which requests are listened | <!-- markdownlint-disable-line -->
6490
- | certificate | hash | nil | Certificate information (if HTTPS) |
6491
- | certificate.key | string | nil | Path to private key file |
6492
- | certificate.cert | string | nil | Path to certificate |
6493
- | certificate.chain | string | nil | Path to intermediary certificates |
6494
- | processing | hash | nil | Behavior of post processing |
6495
- | processing.script_folder | string | . | Prefix added to script path |
6496
- | processing.fail_on_error | bool | false | Fail if true and process exit with non zero |
6497
- | processing.timeout_seconds | integer | 60 | Max. execution time before script is killed |
6611
+ | url | `String` | http://localhost:8080 | Base url on which requests are listened | <!-- markdownlint-disable-line -->
6612
+ | certificate | `Hash` | nil | Certificate information (if HTTPS) |
6613
+ | certificate.key | `String` | nil | Path to private key file |
6614
+ | certificate.cert | `String` | nil | Path to certificate |
6615
+ | certificate.chain | `String` | nil | Path to intermediary certificates |
6616
+ | processing | `Hash` | nil | Behavior of post processing |
6617
+ | processing.script_folder | `String` | . | Prefix added to script path |
6618
+ | processing.fail_on_error | `Bool` | false | Fail if true and process exit with non zero |
6619
+ | processing.timeout_seconds | `Integer` | 60 | Max. execution time before script is killed |
6498
6620
 
6499
6621
  Parameter `url` defines:
6500
6622
 
@@ -6551,6 +6673,8 @@ curl -H "Authorization: $(ascli ascli bearer)" https://faspex5.example.com/asper
6551
6673
 
6552
6674
  ## Plugin: `faspex`: IBM Aspera Faspex v4
6553
6675
 
6676
+ > **Note:** Faspex v4 is end of support since Sept. 30th, 2024. So this plugin for faspex v4 is deprecated. If you still need to use Faspex4, then use `ascli` version 4.19.0 or earlier.
6677
+ >
6554
6678
  > **Note:** For full details on Faspex API, refer to: [Reference on Developer Site](https://developer.ibm.com/apis/catalog/?search=faspex)
6555
6679
 
6556
6680
  This plugin uses APIs versions 3 Faspex v4.
@@ -7281,6 +7405,7 @@ If the preview generator does not have access to files on the file system (it is
7281
7405
 
7282
7406
  ```bash
7283
7407
  check --skip-types=office
7408
+ events --once-only=yes --skip-types=office --log-level=info
7284
7409
  scan --scan-id=1 --skip-types=office --log-level=info --file-access=remote --ts=@json:'{"target_rate_kbps":1000000}'
7285
7410
  scan --skip-types=office --log-level=info
7286
7411
  show --base=test my_docx
@@ -7385,7 +7510,7 @@ Interesting `ascp` features are found in its arguments: (see `ascp` manual):
7385
7510
 
7386
7511
  > **Note:** `ascli` takes transfer parameters exclusively as a [**transfer-spec**](#transfer-specification), with `ts` option.
7387
7512
  >
7388
- > **Note:** Most, but not all, native `ascp` arguments are available as standard [**transfer-spec**](#transfer-specification) parameters.
7513
+ > **Note:** Usual native `ascp` arguments are available as standard [**transfer-spec**](#transfer-specification) parameters, but not special or advanced options.
7389
7514
  >
7390
7515
  > **Note:** Only for the [`direct`](#agent-direct) transfer agent (not others, like connect or node), native `ascp` arguments can be provided with parameter `ascp_args` of option `transfer_info` .
7391
7516