Commit graph

24 commits

Author SHA1 Message Date
Evgenii Stratonikov
ad81b6c90a [#1555] neofs-adm: Remove trailing dots from help messages
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
2022-06-28 13:46:02 +03:00
Leonard Lyubich
2e4a1cb6df [#1518] Upgrade NeoFS SDK Go with changed subnet package
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2022-06-15 17:02:49 +03:00
Pavel Karpy
4ed3063212 [#1466] adm: Remove notary flag in for subnet command
It is possible to deduce that information from the network.

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
2022-06-08 11:06:19 +03:00
Pavel Karpy
815e02f185 [#1466] adm: Do not use morph client in adm
Using morph client leads to requiring WebSocket endpoints.

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
2022-06-08 11:06:19 +03:00
Leonard Lyubich
bb25ecbd15 [#1400] owner: Upgrade SDK package
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2022-05-23 15:33:14 +03:00
Pavel Karpy
697c12a5e9 [#1223] amd: Fix subnet node command
Added `-w` flag.

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
2022-03-10 19:23:39 +03:00
Evgenii Stratonikov
e21d054fe2 [#749] morph/client: set group signer scope
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
2022-02-11 13:26:27 +03:00
Pavel Karpy
fee2f5a330 [#1100] *: Adopt new SDK's owner.ID API
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
2022-01-21 17:58:30 +03:00
Evgenii Stratonikov
5828f43e52 [#851] util/rand: use single random source
It is much more convenient to skip source creation.
Also fix some bugs:
1. `cryptoSource.Int63()` now returns number in [0, 1<<63) as required
   by `rand.Source` interface.
2. Replace `cryptoSource.Uint63()` with `cryptoSource.Uint64` to allow
   generate uint64 numbers directly (see rand.Source64 docs).

Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
2022-01-12 19:29:27 +03:00
Alex Vanin
d89ffbfbdf [#1020] neofs-adm: Make key flag non global in subnet
Key flag should not be global because `subnet get` command
does not require any credentials.

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2021-12-08 18:49:41 +03:00
Alex Vanin
3bb67075f4 [#1020] neofs-adm: Do not ask key in morph subnet get command
There is no need to provide credential to fetch public data from
side chain.

Signed-off-by: Alex Vanin <alexey@nspcc.ru>
2021-12-08 18:49:41 +03:00
Pavel Karpy
15ff98c229 [#1024] adm: Change private key to wallet in subnet flags
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
2021-12-08 15:57:22 +03:00
Pavel Karpy
b4c36a109d [#1019] adm: Fetch subnet SH from NNS
Also, delete `-a` (`--contract`) flag.

Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
2021-12-08 13:33:36 +03:00
Leonard Lyubich
1b698867a7 [#979] adm/subnet: Fix typos
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
dd2998d724 [#979] adm/subnet: Rename id flag to node in node cmd
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
5f915dfb43 [#979] adm/subnet: Rename id flag to admin in admin cmd
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
cc8a0037e0 [#979] adm/subnet: Fix print out of subnet info in get cmd
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
3fcd7bc948 [#979] adm/subnet: Always set group ID parameter in client cmds
Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
4d79195ede [#979] adm/subnet: Fix notary issues
Only `subnet create` command can generate notary requests.

Remove global `non-notary` flag. Add `notary` flag to `create` cmd.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
98e0792b08 [#979] adm/subnet: Add commands to add/remove nodes
Implement `ManageNodes` operation on morph subnet client.
 Add `node add` and `node remove` commands to `subnet` section.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
579c3717a5 [#979] adm/subnet: Inherit pre-run functions in child commands
Cobra commands don't call `PreRun` functions on parent by default. We
need to do it in `subnet` command of admin utility in order to inherit
viper bindings.

Add `inheritPreRun` function which makes sub-commands to call `PreRun`
functions before its own `PreRun`.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
6facc26cb9 [#979] adm/subnet: Fix handling of non-notary flag in initClient
`initSubnetClient` must call `EnableNotarySupport` only if non-notary
flag is not set.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
4b8ca75274 [#979] adm: Fix problems after testing
Use persistent flags on parent command in order to inherit flags in
sub-commands. Turn on notary mode of morph client in `subnet` command of
admin utility for notary environments.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00
Leonard Lyubich
e8f8e58e90 [#979] adm: Add subnet-related commands
Add `subnet` command which contains all subnet-related commands. Add
sub-commands:
  * `create` for creation;
  * `remove` for removal;
  * `get` for reading;
  * `admin` for admin management;
  * `client` for client management.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
2021-12-01 17:31:04 +03:00